QLocale::system If you starting application from sdk it's not using system environment, you should set environment variables door your project manually.
ср, 29 мая 2019 г., 17:32 Tamas Miklos <u...@freemail.hu>: > Hi Guys, > > > Thank you for your replies and comments. I've finally given in and opted > for ... > > https://wiki.qt.io/How_to_do_dynamic_translation_in_QML > > ... and it seems to work well. Sadly I couldn't figure out how to detect > the SFOS system language and use it as the default language of my app. > > > Thanks, > Tamas > > -----Original Message----- > From: Tamas Miklos <u...@freemail.hu> > Sent: Sunday, May 26, 2019 10:39 PM > To: 'devel@lists.sailfishos.org' <devel@lists.sailfishos.org> > Subject: Dynamic QML refresh (localization) > > Hi, > > > Is it possible to dynamically update QML strings after a language change > initiated by the user from the Settings page of my app? In QT there's a > QqmlEngine::retranslate() call, but I couldn't find a way to use that from > a Sailfish app. I've found the following page as well, but it seems way > too overkill to my liking :) > > https://wiki.qt.io/How_to_do_dynamic_translation_in_QML > > I've also found some apps to use the PageStack replace trick to refresh an > already rendered QML page after language change, but it also seems too > quirky to me. > > Please let me know what's the best way to achieve a user-friendly way of > changing language of my app on-the-fly. > > > Thanks, > Tamas (author of AIDA64 for Sailfish) > > _______________________________________________ > SailfishOS.org Devel mailing list > To unsubscribe, please send a mail to > devel-unsubscr...@lists.sailfishos.org
_______________________________________________ SailfishOS.org Devel mailing list To unsubscribe, please send a mail to devel-unsubscr...@lists.sailfishos.org