Opened 22 months ago

Closed 6 weeks ago

#305 closed defect (wontfix)

Application icon is unavailable in (e.g.) MessageBox::about() when ICO is used.

Reported by: ataylor Owned by:
Priority: trivial Milestone: Qt 5
Component: General Version: 4.7.3
Severity: low Keywords:


QIcon apparently does not support the OS/2 Icon format. (This is not really surprising.) However, relying on an Icon resource in a .RC allows the application icon to use a proper OS/2 multi-image icon to be used, which is nice. Presumably this is because the OS handles the rendering and not Qt.

However, doing it this way appears to mean that Qt cannot access the application icon for other purposes.

In particular: creating an 'about' dialog with QMessageBox::about() is supposed to (according to the Qt4 docs) use the application or parent widget's icon if it exists, or use the generic Information icon otherwise.
However, the actual result in this case is no icon at all. I assume this is because Qt4 'knows' there's an application icon, so it doesn't fall back to the Information icon... but the application icon is in a format it can't draw, so it ends up drawing nothing.

I assume other contexts would also be unable to render the application icon. If support for OS/2 Icon cannot easily be added, perhaps the failure logic could be improved.

Change History (2)

comment:1 Changed 11 months ago by diver

  • Milestone changed from Qt4 4.7.3 rerelease to Qt 5

Ticket retargeted after milestone closed

comment:2 Changed 6 weeks ago by diver

  • Resolution set to wontfix
  • Status changed from new to closed

please retest with Qt 5 and open a ticket at if it's not working as you hoped.

Note: See TracTickets for help on using tickets.