Results 1 to 3 of 3

Thread: Translation when using Qt-Creator forms

  1. #1
    Join Date
    Aug 2012
    Location
    Brøndby, Denmark
    Posts
    3
    Thanks
    1
    Qt products
    Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Maemo/MeeGo

    Question Translation when using Qt-Creator forms

    Hello

    How does one come about adding localization support to ones Qt-widget app, when using Qt-Creator forms ?
    Since this means the strings are defined in XML instead.


    In advance
    Many thanks
    Peter

  2. #2
    Join Date
    Jul 2008
    Posts
    408
    Thanks
    9
    Thanked 52 Times in 50 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: Translation when using Qt-Creator forms

    Hi, when you look at the ui_XYZ.h file that is generated from XYZ.ui, you will see that all strings are wrapped in QApplication::translate(). You can translate them using Qt Linguist like any other string.

    Ginsengelf

  3. The following user says thank you to Ginsengelf for this useful post:

    flywheel (1st September 2012)

  4. #3
    Join Date
    Aug 2012
    Location
    Brøndby, Denmark
    Posts
    3
    Thanks
    1
    Qt products
    Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Maemo/MeeGo

    Default Re: Translation when using Qt-Creator forms

    That's awesome - thanks Ginsengelf

    Then I only will need to run lupdate and I've got the necessary .ts files ?

    Many regards
    flywheel

Similar Threads

  1. Replies: 1
    Last Post: 27th July 2012, 12:45
  2. Qt Creator Multiple Forms
    By hkaraoguz84 in forum Qt Programming
    Replies: 7
    Last Post: 8th September 2010, 14:44
  3. translation
    By weixj2003ld in forum Qt Programming
    Replies: 8
    Last Post: 31st May 2010, 01:01
  4. Multiple Forms and vertical layout in forms
    By eva2002 in forum Qt Programming
    Replies: 0
    Last Post: 13th January 2010, 05:05
  5. Layouting "Windows.Forms" like Qt forms
    By Boron in forum Qt Tools
    Replies: 1
    Last Post: 29th April 2008, 22:01

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.