Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Question about qrc and file structure
Qt 6.11 is out! See what's new in the release blog

Question about qrc and file structure

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
1 Posts 1 Posters 432 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.
  • E Offline
    E Offline
    efdiloreto
    wrote on last edited by
    #1

    I am trying to organize the files and I have some doubts about it.

    I have the following file structure:

    ├── Pip-Boy.pro
    ├── Pip-Boy.pro.user
    ├── README.md
    └── src
        ├── main.cpp
        ├── qml
        │   ├── main.qml
        │   └── PipMainButtonTab.qml
        └── qml.qrc
    
    

    The qml.qrc file is:

    <RCC>
        <qresource prefix="/">
            <file>qml/main.qml</file>
            <file>qml/PipMainButtonTab.qml</file>
        </qresource>
    </RCC>
    

    The only way to get the program works is importing the qml directory in main.qml

    import "qrc:/qml"
    

    Why I have to import the qml directory if main.qml is in this folder?

    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