[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Re: kmidi fix
From:       John Corey <whoop () mtco ! com>
Date:       1999-07-22 15:11:45
[Download RAW message or body]

Waldo Bastian wrote:
> 2)
> If you want to find resources like e.g. images which are part of
> your application, instead of
> > !   QString pixdir = thisapp->kde_datadir() + "/kmidi/pics/";
> > !
> >
> >     QPixmap pm(pixdir + "kmidilogo.xpm");
> 
> Use this:
> 
> QPixmap pm(Icon("kmidilogo.xpm"));
> 
> Don't forget to include kglobal.h and kiconloader.h

Icon() does not work with a "pics" dir.  Instead you'd have to do
something like a loadApplicationIcon(locate("toolbar",
"kmidilogo.xpm")).  I believe if the directory is "icons" it does work
though.

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic