[PyQt] Internationalisation
Jeremy Sanders
jeremy at jeremysanders.net
Mon Dec 12 16:50:25 GMT 2011
Hi - are most people using gettext or Qt for their internationalisation?
I played with pylupdate, but it doesn't always find the strings. For
instance I can't do something like
def mytr(text):
return QApplication.translate("myclass", text)
class myclass:
....
def __init__(self):
foo = mytr("hello")
I wonder whether it is worth making a simple Python-based version of
pylupdate. It could use the ast module to get a tree of the python code to
find calls to translation functions. The user could mark their translation
function with something in the docstring for the parser to interpret.
Jeremy
--
http://www.jeremysanders.net/
More information about the PyQt
mailing list