Results 1 to 19 of 19

Thread: Qt has no dependences?

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,376
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Thanks
    4
    Thanked 5,019 Times in 4,795 Posts
    Wiki edits
    10

    Default Re: Qt has no dependences?

    You have no "1.jpg" in the qrc file, you only have ":/new/prefix1/1.jpg".
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  2. #2
    Join Date
    Jan 2011
    Posts
    128
    Thanks
    2

    Default Re: Qt has no dependences?

    Quote Originally Posted by wysota View Post
    You have no "1.jpg" in the qrc file, you only have ":/new/prefix1/1.jpg".
    Sorry what?
    There is a 1.jpg "declared" in the qrc

  3. #3
    Join Date
    Sep 2009
    Location
    Wroclaw, Poland
    Posts
    1,394
    Qt products
    Qt4 Qt5
    Platforms
    MacOS X Unix/X11 Windows Android
    Thanked 342 Times in 324 Posts

    Default Re: Qt has no dependences?

    But you have defined a prefix for the images, which means you have to use it (prefix) when accessing the resources.

  4. #4
    Join Date
    Jan 2011
    Posts
    128
    Thanks
    2

    Default Re: Qt has no dependences?

    Quote Originally Posted by stampede View Post
    But you have defined a prefix for the images, which means you have to use it (prefix) when accessing the resources.
    Removed.Still same effect
    Qt Code:
    1. <RCC>
    2. <qresource>
    3. <file>1.jpg</file>
    4. <file>ex.png</file>
    5. <file>o.png</file>
    6. <file>icon.png</file>
    7. </qresource>
    8. </RCC>
    To copy to clipboard, switch view to plain text mode 

  5. #5
    Join Date
    Sep 2009
    Location
    Wroclaw, Poland
    Posts
    1,394
    Qt products
    Qt4 Qt5
    Platforms
    MacOS X Unix/X11 Windows Android
    Thanked 342 Times in 324 Posts

    Default Re: Qt has no dependences?

    How do you access the images ? If you write QImage("1.jpg") you are not referencing the image from resource system, you have to use the colon - QImage(":/1.jpg"). It's written in the resource system documentation.

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
  •  
Qt is a trademark of The Qt Company.