diff --git a/__main__.py b/__main__.py index 82f0188..6494d76 100755 --- a/__main__.py +++ b/__main__.py @@ -1,7 +1,8 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 #-*-coding:utf-8-*- import sqlite3 -import tkinter as tk +import sys +from PyQt4 import QtGui, uic def table2list(table_tsv): with open(table_tsv,'r',encoding='utf-16') as tsv: @@ -75,7 +76,6 @@ def rawcode2truecode(raw): return true_code - db,c = import_all_table() find_code("越",c) diff --git a/ui.py b/ui.py new file mode 100644 index 0000000..8ae6e66 --- /dev/null +++ b/ui.py @@ -0,0 +1,71 @@ +# -*- coding: utf-8 -*- + +# Form implementation generated from reading ui file 'ui.ui' +# +# Created: Tue Mar 15 02:00:27 2016 +# by: PyQt4 UI code generator 4.10.4 +# +# WARNING! All changes made in this file will be lost! + +from PyQt4 import QtCore, QtGui + +try: + _fromUtf8 = QtCore.QString.fromUtf8 +except AttributeError: + def _fromUtf8(s): + return s + +try: + _encoding = QtGui.QApplication.UnicodeUTF8 + def _translate(context, text, disambig): + return QtGui.QApplication.translate(context, text, disambig, _encoding) +except AttributeError: + def _translate(context, text, disambig): + return QtGui.QApplication.translate(context, text, disambig) + +class Ui_Dialog(object): + def setupUi(self, Dialog): + Dialog.setObjectName(_fromUtf8("Dialog")) + Dialog.resize(392, 321) + self.verticalLayout_2 = QtGui.QVBoxLayout(Dialog) + self.verticalLayout_2.setObjectName(_fromUtf8("verticalLayout_2")) + self.verticalLayout = QtGui.QVBoxLayout() + self.verticalLayout.setObjectName(_fromUtf8("verticalLayout")) + self.scrollArea = QtGui.QScrollArea(Dialog) + self.scrollArea.setWidgetResizable(True) + self.scrollArea.setObjectName(_fromUtf8("scrollArea")) + self.scrollAreaWidgetContents = QtGui.QWidget() + self.scrollAreaWidgetContents.setGeometry(QtCore.QRect(0, -14, 357, 706)) + self.scrollAreaWidgetContents.setObjectName(_fromUtf8("scrollAreaWidgetContents")) + self.horizontalLayout = QtGui.QHBoxLayout(self.scrollAreaWidgetContents) + self.horizontalLayout.setObjectName(_fromUtf8("horizontalLayout")) + self.label = QtGui.QLabel(self.scrollAreaWidgetContents) + sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Minimum) + sizePolicy.setHorizontalStretch(0) + sizePolicy.setVerticalStretch(0) + sizePolicy.setHeightForWidth(self.label.sizePolicy().hasHeightForWidth()) + self.label.setSizePolicy(sizePolicy) + self.label.setTextFormat(QtCore.Qt.AutoText) + self.label.setWordWrap(True) + self.label.setOpenExternalLinks(True) + self.label.setTextInteractionFlags(QtCore.Qt.LinksAccessibleByKeyboard|QtCore.Qt.LinksAccessibleByMouse|QtCore.Qt.TextBrowserInteraction|QtCore.Qt.TextSelectableByKeyboard|QtCore.Qt.TextSelectableByMouse) + self.label.setObjectName(_fromUtf8("label")) + self.horizontalLayout.addWidget(self.label) + self.scrollArea.setWidget(self.scrollAreaWidgetContents) + self.verticalLayout.addWidget(self.scrollArea) + self.verticalLayout_2.addLayout(self.verticalLayout) + self.buttonBox = QtGui.QDialogButtonBox(Dialog) + self.buttonBox.setOrientation(QtCore.Qt.Horizontal) + self.buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Ok) + self.buttonBox.setObjectName(_fromUtf8("buttonBox")) + self.verticalLayout_2.addWidget(self.buttonBox) + + self.retranslateUi(Dialog) + QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("accepted()")), Dialog.accept) + QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("rejected()")), Dialog.reject) + QtCore.QMetaObject.connectSlotsByName(Dialog) + + def retranslateUi(self, Dialog): + Dialog.setWindowTitle(_translate("Dialog", "Dialog", None)) + self.label.setText(_translate("Dialog", "
findarray30code
0.0.1
查詢行列 30 輸入法碼表的工具。
支援 CJK Ext. A - E 的罕字。
https://github.com/Yoxem/findarray30code
Copyright (C) 2016
Yoxem Chen (aka Kian-ting Tan)
under X11 License
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
", None)) + diff --git a/ui.ui b/ui.ui index 0587858..7ba80b0 100644 --- a/ui.ui +++ b/ui.ui @@ -1,129 +1,112 @@