diff options
-rwxr-xr-x | contrib/tdepyuic | 32 | ||||
-rw-r--r-- | examples/qxembedexample.py | 5 | ||||
-rw-r--r-- | examples/uiqxembed.py | 4 |
3 files changed, 20 insertions, 21 deletions
diff --git a/contrib/tdepyuic b/contrib/tdepyuic index e9acd45..a38f89b 100755 --- a/contrib/tdepyuic +++ b/contrib/tdepyuic @@ -31,13 +31,13 @@ import sys, getopt, os, os.path, string #---------- globals ---------- -FALSE = 0 -TRUE = not FALSE -addApp = TRUE -addImport = TRUE -pyuicPath = "pyuic" -filename = "" -i18nFunc = FALSE +FALSE = 0 +TRUE = not FALSE +addApp = TRUE +addImport = TRUE +pytquicPath = "pytquic" +filename = "" +i18nFunc = FALSE # --------- support functions ---------- @@ -47,7 +47,7 @@ def getOptions (): opterr = 0 shortOptions = 'aip:' - longOptions = ['noapp', 'noimport', 'pyuic=', 'usetdei18n'] + longOptions = ['noapp', 'noimport', 'pytquic=', 'usetdei18n'] try: optlist, args = getopt.getopt (sys.argv [1:], shortOptions, longOptions) @@ -64,7 +64,7 @@ def getOptions (): Options: -a, --noapp Don't add TDEApplication code -i, --noimport Don't add tdecore, tdeui import statements - -p, --pyuic Path to pyuic program + -p, --pytquic Path to pytquic program --usetdei18n Adds TDEs default i18n functions to your Python TDE ui file """) return FALSE @@ -73,7 +73,7 @@ def getOptions (): return checkOptions (optlist) def checkOptions (optlist): - global addApp, addImport, pyuicPath, i18nFunc + global addApp, addImport, pytquicPath, i18nFunc for pair in optlist: if (pair [0] == '--noapp') or (pair [0] == '-a'): @@ -82,8 +82,8 @@ def checkOptions (optlist): elif (pair [0] == '--noimport') or (pair [0] == '-i'): addImport = FALSE - elif (pair [0] == '--pyuic') or (pair [0] == '-p'): - pyuicPath = pair [1] + elif (pair [0] == '--pytquic') or (pair [0] == '-p'): + pytquicPath = pair [1] if (pair [0] == '--usetdei18n'): i18nFunc=TRUE @@ -109,7 +109,7 @@ def addapp (indent, n): n.write (indent + 'TDECmdLineArgs.init (sys.argv, appname, description, version)\n') n.write (indent + 'a = TDEApplication ()\n\n') -def doPyuic (): +def doPytquic (): fn = os.path.splitext (os.path.basename(filename)) [0] + '.py' opts = "" @@ -123,8 +123,8 @@ def doPyuic (): opts = opts + ' -o ' - if os.system (pyuicPath + opts + fn + ' ' + filename) != 0: - print(pyuicPath + opts + fn + ' ' + filename + " failed") + if os.system (pytquicPath + opts + fn + ' ' + filename) != 0: + print(pytquicPath + opts + fn + ' ' + filename + " failed") sys.exit (-1) if addApp or addImport: @@ -160,4 +160,4 @@ def doPyuic (): # --------- main ---------- getOptions () -doPyuic () +doPytquic () diff --git a/examples/qxembedexample.py b/examples/qxembedexample.py index 82c2c92..da9c45b 100644 --- a/examples/qxembedexample.py +++ b/examples/qxembedexample.py @@ -2,8 +2,7 @@ # Form implementation generated from reading ui file 'qxembedexample.ui' # -# Created: Thu Apr 29 02:17:37 2004 -# by: The PyTQt User Interface Compiler (pyuic) 3.11 +# Created by: The PyTQt User Interface Compiler (pytquic) 3.18.1 # # WARNING! All changes made in this file will be lost! @@ -47,7 +46,7 @@ class QXEmbedExample(TQWidget): self.textLabel1 = TQLabel(self.tab,"textLabel1") tabLayout.addWidget(self.textLabel1) - self.mainTabs.insertTab(self.tab,TQString("")) + self.mainTabs.insertTab(self.tab,TQString.fromUtf8("")) QXEmbedExampleLayout.addWidget(self.mainTabs) self.languageChange() diff --git a/examples/uiqxembed.py b/examples/uiqxembed.py index bbeae5a..9778e1e 100644 --- a/examples/uiqxembed.py +++ b/examples/uiqxembed.py @@ -11,7 +11,7 @@ from tdecore import KWin, KWinModule from tdeui import KComboBox, TDEMainWindow, KPushButton, QXEmbed -## add the missing items to the pyuic-generated module +## add the missing items to the pytquic-generated module import qxembedexample qxembedexample.KComboBox = KComboBox qxembedexample.KPushButton = KPushButton @@ -43,7 +43,7 @@ def getWindow(pid): class ExampleForm(QXEmbedExample): - """ wraps the pyuic generated form class with our behavior + """ wraps the pyqtuic generated form class with our behavior """ def __init__(self, parent): |