The Following 4 Users Say Thank You to EmaNymton For This Useful Post: | ||
|
2015-03-22
, 21:14
|
Posts: 1 |
Thanked: 0 times |
Joined on Mar 2015
|
#102
|
|
2015-07-18
, 15:18
|
Posts: 1,548 |
Thanked: 7,510 times |
Joined on Apr 2010
@ Czech Republic
|
#103
|
Any advice on how to handle translations of strings in Python code? In particular when doing string formatting in Python and the unformatted string should be subject to translation.
Is there a way to access ts-file data from Python without importing some huge PyQt? Or am I just wrong to put strings in Python and should move them all to QML? The whole Qt translation system seems very primitive compared to gettext.
https://github.com/otsaloma/poor-maps/issues/1
|
2016-08-07
, 11:35
|
Posts: 1,548 |
Thanked: 7,510 times |
Joined on Apr 2010
@ Czech Republic
|
#105
|
The Following 2 Users Say Thank You to MartinK For This Useful Post: | ||
|
2017-01-29
, 23:11
|
Posts: 1,548 |
Thanked: 7,510 times |
Joined on Apr 2010
@ Czech Republic
|
#106
|
The Following 10 Users Say Thank You to MartinK For This Useful Post: | ||
|
2017-04-24
, 14:15
|
Posts: 1,548 |
Thanked: 7,510 times |
Joined on Apr 2010
@ Czech Republic
|
#107
|
The Following 15 Users Say Thank You to MartinK For This Useful Post: | ||
If you use sailfish-qml to start your PyOtherSide/QML application you have to place your qm-translation files in a folder called translations.
Translation files are supposed to be named "<appname>-<lang>.qm" in "/usr/share/<appname>/translations/"
That works for me, found it at the source code of sailfishlib project:
https://github.com/sailfish-sdk/libs...shapp_priv.cpp