mattia
14th November 2007, 16:45
I have a translation problem in my application.
In the main i'm setting the language in this way:
QApplication app ( argc, argv );
QTranslator translator;
translator.load ( "/home/mattia/workspace/myProject/translations/trm_it" );
app.installTranslator ( &translator );
......
If i want to set as default language "en" i have to do:
translator.load ( "/home/mattia/workspace/myProject/translations/trm_en" );
and it is correctly loaded, when i'm at runtime i want to change the language and i made a dialog widget to allow the user to insert a language, for example "en", but i don't know how performe the change language at runtime.
Is it possible do it?
Thanks
In the main i'm setting the language in this way:
QApplication app ( argc, argv );
QTranslator translator;
translator.load ( "/home/mattia/workspace/myProject/translations/trm_it" );
app.installTranslator ( &translator );
......
If i want to set as default language "en" i have to do:
translator.load ( "/home/mattia/workspace/myProject/translations/trm_en" );
and it is correctly loaded, when i'm at runtime i want to change the language and i made a dialog widget to allow the user to insert a language, for example "en", but i don't know how performe the change language at runtime.
Is it possible do it?
Thanks