From kde-panel-devel Tue Mar 31 16:21:17 2009 From: "Aaron J. Seigo" Date: Tue, 31 Mar 2009 16:21:17 +0000 To: kde-panel-devel Subject: Re: Unable to load images for pushbuttons from relative path Message-Id: <200903311021.18324.aseigo () kde ! org> X-MARC-Message: https://marc.info/?l=kde-panel-devel&m=123851654730649 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--===============0485988368==" --===============0485988368== Content-Type: multipart/signed; boundary="nextPart6835917.X9bivIzull"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit --nextPart6835917.X9bivIzull Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable On Tuesday 31 March 2009, Eitzenberger Thomas wrote: > Hi, > > someone on #plasma told me i could ask for help via this emailaddr too..= =2E. > > I need a pushbutton in the parley applet to trigger playing the sound file > > The button shall show up green if the url is valid and orange if not, grey > if checking/ongoing > > Up to now I was only able to get the pushbutton showing up with the images > using absolute URLS > > I tried with "widgets/play_green.png" "widgets/play_green" and also tried > to embedd teh images in to the svg file but there I am stranded as the > PushButton doesnt want a QPixmap but a path QString..... png files shouldn't be installed into the theme, as it only deals with svg= =20 files.=20 i can think of a couple of different ways to go about this: * install the png's into apddata and then use KStandardDirs to find it, e.g= =2E: KGlobal::dirs()->locate("appdata", "parley/play_green.png"); * put all of the png's into an svg file, install that into the theme as you= =20 have done and then we could add to the widget API something like: void setImage(const QString &path, const QString &elementId) that would paint just the svg element from the svg, much as IconWidget does= =2E=20 this would only work for kde 4.3 and beyond, however. thoughts? =2D-=20 Aaron J. Seigo humru othro a kohnu se GPG Fingerprint: 8B8B 2209 0C6F 7C47 B1EA EE75 D6B7 2EB1 A7F1 DB43 KDE core developer sponsored by Qt Software --nextPart6835917.X9bivIzull Content-Type: application/pgp-signature; name=signature.asc Content-Description: This is a digitally signed message part. -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.9 (GNU/Linux) iEYEABECAAYFAknSQv4ACgkQ1rcusafx20NAAACghZUAFpTCLzkYvMRV06b5CTbs 5gAAnRqubjagu23uD1vmoYNOUzREEj05 =uFh3 -----END PGP SIGNATURE----- --nextPart6835917.X9bivIzull-- --===============0485988368== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel --===============0485988368==--