Results 1 to 3 of 3

Thread: QResource registering two resources with same file names inside

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Dec 2010
    Location
    Israel
    Posts
    90
    Thanks
    59
    Thanked 2 Times in 2 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Question QResource registering two resources with same file names inside

    I'm working with pre-generated "rcc" resource files I'm loading during run-time.

    I want to have a hierarchical resource mechanism - one "rcc" file has resources on the application level. After that a user specific resource file is registered.

    If both of my resource files have the file "logo.png", after registering both rcc files with QResource::registerResource how can I differentiate the two different files?

    I understand I could use the alias mechanism (or alternatively the prefix) to make sure every access is fully qualified ":global/logo" as opposed to ":user/logo") BUT then I'd have to wrap every access so that the user accesses the correct file.

    Ideally I'd have some way of saying ":logo.png" and getting the correct file based on the user's resource override.

    Any tips on the matter?

    Also - is the default behavior overriding the files? I coded it and think it is but just to be sure...
    Last edited by frankiefrank; 26th April 2011 at 17:37.

Similar Threads

  1. Accessing version resources from inside the app
    By bnilsson in forum Qt Programming
    Replies: 5
    Last Post: 27th February 2010, 18:54
  2. QtHelp Module - registering compressed help file gives error
    By Ankitha Varsha in forum Qt Programming
    Replies: 1
    Last Post: 16th May 2008, 14:14
  3. qresource file alias problem with svg
    By giotto in forum Qt Programming
    Replies: 2
    Last Post: 19th February 2008, 15:59
  4. moc with same file names?
    By cjhuitt in forum Qt Programming
    Replies: 9
    Last Post: 27th April 2007, 20:36
  5. Reading a unicode names from a file???
    By darpan in forum Qt Programming
    Replies: 7
    Last Post: 3rd May 2006, 17:28

Tags for this Thread

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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.