QT Linguist
-
I spent several hours yesterday using Qt Linguist providing translations for all the text in my application. Today I noticed one of the forms didn't have translation, I cleaned the application and remade, however not I find that all the work I did yesterday is gone.
Every translation is empty, why? what has caused this?
Are the line numbers in the ts XML file relevant and actually used?
-
@SPlatten I don't really understand what you have done, sorry.
To update translation source file (ts), you have to use lupdate. There is no need to recompile the application for that.
AFAIK, the line number is only used by the Qt linguist to show the context.
-
@KroMignon , live and learn, I checked it out from git again, so back where I was, is there any way to partially update the ts without loosing everything?
For example if a new form is added to the application, how to add that to an existing translation file?
-
@SPlatten said in QT Linguist:
I checked it out from git again, so back where I was, is there any way to partially update the ts without loosing everything?
For example if a new form is added to the application, how to add that to an existing translation file?I don't know how you use lupdate, per default nothing is removed from ts file. To remove entries from ts, you have to add --no-obsolete.
REM update translation files lupdate -pro <project_file_name> REM update and remove old strings lupdate -pro <project_file_name> --no-obsolete