Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Localisation with Flags?

Localisation with Flags?

Scheduled Pinned Locked Moved Unsolved General and Desktop
2 Posts 2 Posters 231 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • BDC_PatrickB Offline
    BDC_PatrickB Offline
    BDC_Patrick
    wrote on last edited by
    #1

    Hi there..
    I've a small Question I couldn't find an answer to..

    The Situation is:
    When I create Labels/Texts with tr(""), I can create a QT Localisation file.
    Within this file, all texts are listed..
    so long, so good..

    Now, I created around 100 different Dialogs.. each one has two or three Buttons with (opt. Apply), OK and Cancel.

    Refreshing the Localisation file.. I now have 100 times "Oak".. 100 times "Cancel".. and over 40 times "Apply"..

    so. more work than necessary..

    Perhaps.. someone can lead me into the correct Direction..

    How can I add a Language Flag.. like..
    %confirm%, %cancel% and %apply%

    so I only have each entry only one time for all Dialogs project wide, instead of hundreds over hundreds of it..?

    1 Reply Last reply
    0
    • Christian EhrlicherC Online
      Christian EhrlicherC Online
      Christian Ehrlicher
      Lifetime Qt Champion
      wrote on last edited by Christian Ehrlicher
      #2

      Use a custom widget for your Dialog buttons like e.g. QDialogButtonBox.
      Or do a search'n'replace in the ts files. Or use QCoreApplication::translate() to translate those strings (only works when you don't use ui files)

      Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
      Visit the Qt Academy at https://academy.qt.io/catalog

      1 Reply Last reply
      1

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved