[Qt-jambi-interest] Icon problem

Eskil Abrahamsen Blomfeldt eblomfel at trolltech.com
Fri Mar 28 13:50:05 CET 2008


Hi, Bruno.

I've tracked down your bug in QIcon, and wanted to let you know about a 
possible work around for you that you can use until the bugfixed Qt 
Jambi is released. Replace the following line in your code:

Bruno Janvier wrote:
>        but.setIcon(new 
> QIcon("classpath:images/iconshock/48/file_48.png"));


with

    but.setIcon(new QIcon(new 
QPixmap("classpath:images/iconshock/48/file_48.png")));

and I believe it should solve your problem, as it is seems only to be 
the QIcon constructor which takes a String that suffers from the bug.

-- Eskil



More information about the Qt-jambi-interest mailing list