Correctly copy Kanji defintions to clipboard
Former-commit-id: 505fff8db8eabb0abfe1f8ff8e6b411ee520563d
This commit is contained in:
parent
30badd7967
commit
4423e7efc0
@ -221,7 +221,11 @@
|
|||||||
<widget class="QWidget" name="dockWidgetContents_3">
|
<widget class="QWidget" name="dockWidgetContents_3">
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_3">
|
<layout class="QVBoxLayout" name="verticalLayout_3">
|
||||||
<item>
|
<item>
|
||||||
<widget class="QTextBrowser" name="textKanjiDefs"/>
|
<widget class="QTextBrowser" name="textKanjiDefs">
|
||||||
|
<property name="openLinks">
|
||||||
|
<bool>false</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_4">
|
<layout class="QHBoxLayout" name="horizontalLayout_4">
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
# Form implementation generated from reading ui file 'ui/about.ui'
|
# Form implementation generated from reading ui file 'ui/about.ui'
|
||||||
#
|
#
|
||||||
# Created: Mon Nov 11 15:13:30 2013
|
# Created: Thu Nov 14 08:32:50 2013
|
||||||
# by: PyQt4 UI code generator 4.10
|
# by: PyQt4 UI code generator 4.10
|
||||||
#
|
#
|
||||||
# WARNING! All changes made in this file will be lost!
|
# WARNING! All changes made in this file will be lost!
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
# Form implementation generated from reading ui file 'ui/preferences.ui'
|
# Form implementation generated from reading ui file 'ui/preferences.ui'
|
||||||
#
|
#
|
||||||
# Created: Mon Nov 11 15:13:30 2013
|
# Created: Thu Nov 14 08:32:50 2013
|
||||||
# by: PyQt4 UI code generator 4.10
|
# by: PyQt4 UI code generator 4.10
|
||||||
#
|
#
|
||||||
# WARNING! All changes made in this file will be lost!
|
# WARNING! All changes made in this file will be lost!
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
# Form implementation generated from reading ui file 'ui/reader.ui'
|
# Form implementation generated from reading ui file 'ui/reader.ui'
|
||||||
#
|
#
|
||||||
# Created: Mon Nov 11 15:13:30 2013
|
# Created: Thu Nov 14 08:32:50 2013
|
||||||
# by: PyQt4 UI code generator 4.10
|
# by: PyQt4 UI code generator 4.10
|
||||||
#
|
#
|
||||||
# WARNING! All changes made in this file will be lost!
|
# WARNING! All changes made in this file will be lost!
|
||||||
@ -122,6 +122,7 @@ class Ui_MainWindowReader(object):
|
|||||||
self.verticalLayout_3 = QtGui.QVBoxLayout(self.dockWidgetContents_3)
|
self.verticalLayout_3 = QtGui.QVBoxLayout(self.dockWidgetContents_3)
|
||||||
self.verticalLayout_3.setObjectName(_fromUtf8("verticalLayout_3"))
|
self.verticalLayout_3.setObjectName(_fromUtf8("verticalLayout_3"))
|
||||||
self.textKanjiDefs = QtGui.QTextBrowser(self.dockWidgetContents_3)
|
self.textKanjiDefs = QtGui.QTextBrowser(self.dockWidgetContents_3)
|
||||||
|
self.textKanjiDefs.setOpenLinks(False)
|
||||||
self.textKanjiDefs.setObjectName(_fromUtf8("textKanjiDefs"))
|
self.textKanjiDefs.setObjectName(_fromUtf8("textKanjiDefs"))
|
||||||
self.verticalLayout_3.addWidget(self.textKanjiDefs)
|
self.verticalLayout_3.addWidget(self.textKanjiDefs)
|
||||||
self.horizontalLayout_4 = QtGui.QHBoxLayout()
|
self.horizontalLayout_4 = QtGui.QHBoxLayout()
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
# Resource object code
|
# Resource object code
|
||||||
#
|
#
|
||||||
# Created: Mon Nov 11 15:13:30 2013
|
# Created: Thu Nov 14 08:32:50 2013
|
||||||
# by: The Resource Compiler for PyQt (Qt v4.8.4)
|
# by: The Resource Compiler for PyQt (Qt v4.8.4)
|
||||||
#
|
#
|
||||||
# WARNING! All changes made in this file will be lost!
|
# WARNING! All changes made in this file will be lost!
|
||||||
|
@ -131,6 +131,10 @@ def markupKanji(definition):
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
def copyKanjiDef(definition):
|
||||||
|
return QtGui.QApplication.clipboard().setText(u'{character}\t{kunyomi}\t{onyomi}\t{glossary}'.format(**definition))
|
||||||
|
|
||||||
|
|
||||||
def buildDefHeader():
|
def buildDefHeader():
|
||||||
palette = QtGui.QApplication.palette()
|
palette = QtGui.QApplication.palette()
|
||||||
toolTipBg = palette.color(QtGui.QPalette.Window).name()
|
toolTipBg = palette.color(QtGui.QPalette.Window).name()
|
||||||
|
Loading…
Reference in New Issue
Block a user