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. Working with lupdate
QtWS25 Last Chance

Working with lupdate

Scheduled Pinned Locked Moved Unsolved General and Desktop
3 Posts 2 Posters 844 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.
  • R Offline
    R Offline
    RudolfVonKrugstein
    wrote on last edited by
    #1

    To have my translations all being found by lupdate, I have this in my project file:

    lupdate_only {
      SOURCES += *.qml
      SOURCES += folder1/*.qml
      SOURCES += folder2/*.qml
    }
    
    1. it is kind of unpractical, that I have to list all folders manual. Can I somehow "automatic" add all qml files in sub-directories? Like:
    SOURCE += **/*.qml
    
    1. Can I somehow tell qt creator that it should ignore the lupdate_only section? it is annoying, that it pollutes my project view with these files (they already are in qrc section).
    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by SGaist
      #2

      Hi,

      You can try something like:

      SOURCE += $ $files($$PWD/qml/*.qml,true))
      

      Remove the space between the $ in your .pro file.

      Hope it helps

      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
      1
      • R Offline
        R Offline
        RudolfVonKrugstein
        wrote on last edited by
        #3

        Hey,

        Thanks, that works.
        Only thing: qt creator is still showing the files.

        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