Results 1 to 10 of 10

Thread: No icons visible in XP System Tray or Listbox?

  1. #1
    Join Date
    Apr 2010
    Posts
    11
    Thanks
    2
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Windows

    Question No icons visible in XP System Tray or Listbox?

    Hello Qt experts,

    I have made a program that uses the QSystemTray class and a ListBox with icons (like in the System Tray Example). When I run it on Vista, all works perfectly fine. However, when I install either my program or the System Tray Example on XP, none of the icons is visible

    The system-tray is created and even the tooltip is OK, but no icon The listbox does not show any icons either...

    How can I fix this? I know XP supports tray-icons, so at least that should work?

    Thanks in advance.

  2. #2
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: No icons visible in XP System Tray or Listbox?

    I assume the Vista machine is your development environment Have you installed the necessary plugins with your application on the XP machine?

  3. #3
    Join Date
    Apr 2010
    Location
    Rostov-na-Donu, Russia
    Posts
    153
    Thanks
    2
    Thanked 26 Times in 23 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: No icons visible in XP System Tray or Listbox?

    Copy imageformats folder from Qt-dir near to your exe-file on XP-machine

  4. #4
    Join Date
    Apr 2010
    Posts
    11
    Thanks
    2
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: No icons visible in XP System Tray or Listbox?

    Quote Originally Posted by ChrisW67 View Post
    I assume the Vista machine is your development environment Have you installed the necessary plugins with your application on the XP machine?
    Hello Chris,

    What plugins do you mean? I wasn't aware that anything else then the necessary .dll's should be installed

    @borisbn: the imageformats folder? What does that do? Could you elaborate?

  5. #5
    Join Date
    Apr 2010
    Location
    Rostov-na-Donu, Russia
    Posts
    153
    Thanks
    2
    Thanked 26 Times in 23 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: No icons visible in XP System Tray or Listbox?

    images in qt (except of *.PNG) are working via plugin system, e.g. you can add your own image format to qt-application, writing dll in qt-plugin format. There are some formats, included in qt: *.ICO, *.JPG, *.BMP etc. Corresponding dlls must be in folder with name imageformats. copy this folder from %QTDIR%\plugins\imageformats\ near to your application like this
    C:\MyApp\my_app.exe
    C:\MyApp\imageformats

  6. The following user says thank you to borisbn for this useful post:

    V4Friend (20th July 2010)

  7. #6
    Join Date
    Apr 2010
    Posts
    11
    Thanks
    2
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: No icons visible in XP System Tray or Listbox?

    Quote Originally Posted by borisbn View Post
    images in qt (except of *.PNG) are working via plugin system, e.g. you can add your own image format to qt-application, writing dll in qt-plugin format. There are some formats, included in qt: *.ICO, *.JPG, *.BMP etc. Corresponding dlls must be in folder with name imageformats. copy this folder from %QTDIR%\plugins\imageformats\ near to your application like this
    Hello Boris,

    Well, that works! I had to put qico4.dll and qicod4.dll in the folder imageformats.

    Which leads me to another matter: I have compiled my program in Visual Studio. As a matter of fact: I can only compile 'Release', or the program crashes... When I only put qico4.dll in the folder, it did not work. I guess the qico4d.dll is actually a 'debug' version? How could that be right?

  8. #7
    Join Date
    Sep 2009
    Location
    UK
    Posts
    2,447
    Thanks
    6
    Thanked 348 Times in 333 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: No icons visible in XP System Tray or Listbox?

    Quote Originally Posted by V4Friend View Post
    Which leads me to another matter: I have compiled my program in Visual Studio. As a matter of fact: I can only compile 'Release', or the program crashes... When I only put qico4.dll in the folder, it did not work. I guess the qico4d.dll is actually a 'debug' version? How could that be right?
    Yes, qico4d is debug version, you don't need for release.

  9. #8
    Join Date
    Apr 2010
    Posts
    11
    Thanks
    2
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: No icons visible in XP System Tray or Listbox?

    Quote Originally Posted by fatjuicymole View Post
    Yes, qico4d is debug version, you don't need for release.
    That's exactly what puzzels me: if I leave it out, the icons don't show
    So somehow the wrong .dll is required.

    How do I change that? (or should I start another thread?)

  10. #9
    Join Date
    Sep 2009
    Location
    UK
    Posts
    2,447
    Thanks
    6
    Thanked 348 Times in 333 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: No icons visible in XP System Tray or Listbox?

    Which is the biggest file? Debug libraries are always larger than release versions as they (not suprisingly) contain debugging info.

  11. #10
    Join Date
    Apr 2010
    Posts
    11
    Thanks
    2
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: No icons visible in XP System Tray or Listbox?

    Quote Originally Posted by fatjuicymole View Post
    Which is the biggest file? Debug libraries are always larger than release versions as they (not suprisingly) contain debugging info.
    The biggest is, as expected the qicod4.dll The problem is: why does Qt need the debug-version and not the release version.
    Do I have to rebuild Qt or something like that?

Similar Threads

  1. Minimize to system tray
    By aLiNuSh in forum Newbie
    Replies: 17
    Last Post: 4th March 2010, 12:51
  2. How to keep System tray icons
    By mkkguru in forum Qt Programming
    Replies: 10
    Last Post: 24th February 2010, 16:19
  3. how to use System Tray Icons in QToolBar
    By wagmare in forum Qt Programming
    Replies: 2
    Last Post: 13th January 2009, 15:52
  4. Minimize to system tray
    By krivenok in forum Qt Programming
    Replies: 5
    Last Post: 13th January 2009, 04:34
  5. system tray problem
    By vvdounai in forum Qt Programming
    Replies: 5
    Last Post: 14th November 2007, 08:25

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.