Details
-
Suggestion
-
Resolution: Duplicate
-
Not Evaluated
-
None
-
5.15.2
-
None
-
windows 10, python 3.8.7
Description
pyside2-uic general unicode string, which canot detect by both pyside2-lupdate and pylupdate5
- create 'untitled.ui' by pyside2-designer.exe
- pyside2-uic.exe untitled.ui -o ui_untitled.py. The code is unicode string like this:
MainWindow.setWindowTitle(QCoreApplication.translate("MainWindow", u"MainWindow", None))
self.pushButton.setText(QCoreApplication.translate("MainWindow", u"hello world. \u4e2d\u6587", None))
3. pyside2-lupdate -noobsolete ui_untitled.py -ts i18n_pysid2-ludate.ts
(or pylupdate5 -noobsolete ui_untitled.py -ts i18n_pylupdate5.ts)
The result of pyside2-lupdate:
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE TS><TS version="1.1">
</TS>
Maybe i think pyside2-uic.exe should genate UTF-8 Text instead unicode string,like pyuic5.exe:
MainWindow.setWindowTitle(_translate("MainWindow", "MainWindow"))
self.pushButton.setText(_translate("MainWindow", "hello world. 中文"))
Attachments
Issue Links
- duplicates
-
PYSIDE-1717 pyside2-lupdate generated a blank .ts file
-
- Closed
-