diff options
author | ormorph <roma251078@mail.ru> | 2024-04-28 15:13:46 +0300 |
---|---|---|
committer | ormorph <roma251078@mail.ru> | 2024-04-30 05:31:18 +0300 |
commit | f8780f8ac8d4f5955828d8c3a927bed453a3630b (patch) | |
tree | 4b3ce24358d9c031283a3098c5c16773b13db3ad | |
parent | ba0616ea87225f3edcc45dc863d0d03419a53450 (diff) | |
download | pytqt-f8780f8ac8d4f5955828d8c3a927bed453a3630b.tar.gz pytqt-f8780f8ac8d4f5955828d8c3a927bed453a3630b.zip |
Fix example translations for pytqt
Signed-off-by: ormorph <roma251078@mail.ru>
-rwxr-xr-x | examples/i18n/i18n.py | 4 | ||||
-rw-r--r-- | examples/i18n/mywidget.py | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/examples/i18n/i18n.py b/examples/i18n/i18n.py index ef17d27..db23cb6 100755 --- a/examples/i18n/i18n.py +++ b/examples/i18n/i18n.py @@ -2,7 +2,7 @@ # Copyright (c) 2002 Detlev Offenbach <detlev@die-offenbachs.de> -from whrandom import randint +from random import randint import sys from PyTQt.tqt import * @@ -109,7 +109,7 @@ def main(argv): r = dlg.exec_loop() if r: - tight = tqApp.desktop().screen().width < 1024 + tight = tqApp.desktop().screen().width() < 1024 x = 5 y = 25 for i in range(0,len(qm)): diff --git a/examples/i18n/mywidget.py b/examples/i18n/mywidget.py index 681d98a..7dac01c 100644 --- a/examples/i18n/mywidget.py +++ b/examples/i18n/mywidget.py @@ -25,9 +25,9 @@ class MyWidget(TQMainWindow): self.gbox = TQButtonGroup(1, TQGroupBox.Horizontal, self.trUtf8("View"), self.central) - rb = TQRadioButton(tqApp.translate('MyWidget','Perspective'), self.gbox) - rb = TQRadioButton(tqApp.translate('MyWidget','Isometric'), self.gbox) - rb = TQRadioButton(tqApp.translate('MyWidget','Oblique'), self.gbox) + rb = TQRadioButton(tqApp.translate(b'MyWidget',b'Perspective'), self.gbox) + rb = TQRadioButton(tqApp.translate(b'MyWidget',b'Isometric'), self.gbox) + rb = TQRadioButton(tqApp.translate(b'MyWidget',b'Oblique'), self.gbox) self.initChoices(self.central) |