Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Language Bindings
  4. Linguist file *.qm into CMakeList.txt ?
Forum Updated to NodeBB v4.3 + New Features

Linguist file *.qm into CMakeList.txt ?

Scheduled Pinned Locked Moved Unsolved Language Bindings
linguist
2 Posts 2 Posters 1.4k Views 1 Watching
  • 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.
  • R Offline
    R Offline
    Ralf
    wrote on last edited by Ralf
    #1

    I have already created a .qm translation binary with the QLinguist. Now, I would like to add that to my Qt5 project, which does not operate on Qt-Project (.pro) files. We use CMakeList.txt files exclusively..

    I found some examples in the internet, so my CMakeFile contains:

    Find_package(Qt5LinguistTools)
    SET(TRANSLATIONS :/res/translation_german.qm)
    QT5_ADD_TRANSLATION(QM ${TRANSLATIONS}) # this does not make any sense? Since I alread yhave *.qm ?
    /# ..
    appName ${ProgramSources_SRCS} ${TRANSLATIONS} ${programName_ui_H}
    /# Are programName_ui_H all headers where a translation shall take place?
    /# Are ProgramSources_SRCS all headers where a translation shall take place?

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      You have in Qt's cmake documentation the explanation of the variable to use for that.

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0

      • Login

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