I first tried the method you described with drawing qith pycairo. Unfortunately
- it certainly due to my inexperience - I noticed while it's easy to draw a
rectangle on a pixmap (bit image), it was more complicated on a pixbuf
(vectorial image, like the icon is and should stay), and I did not succed.
Show me the way then I'll try again and we will compare the 2 methods.
On the other side, composing with svg with so simple image seems to be
efficient, and one who would change the progress bar appareance would only have
to deal with svg images and not with python coding.
Regards,
Jérôme
Jérôme
De : [EMAIL PROTECTED]
Date : 21/02/08 20:03:49
A : Development for gPodder
Sujet : Re: [gpodder-devel] Proposition: progress bar on the tray icon
Hello, Jérôme!
On Wed, 2008-02-20 at 22:18 +0100, Jérôme Chabod wrote:
> You'll find in attachement a patch which add a progress bar to the tray
> icon during download (you'll also find a small screenshot).
>
> I'm not a great designer, so it's quite simple. It consists of 2 svg
> images: one "gPodder" green rectangle for the background, one dark green
> rectangle for the progress.
> I'm open for any comment or suggestion (horizontal, vertical, diagonal,
> left, right, blue, red, ...), but keep it light...
I think using seperate SVG images for the tray icon is a bit overkill
and strange. You can easily do the same thing using a bit of PyCairo
coding, see src/gpodder/draw.py for examples on how to do it. Basically,
you would load the icon (maybe compose it with the downloading arrow),
then find out where you want to draw the progress bar, draw a rectangle,
set the fill color and fill it and then draw the second rectangle.
That should make the patch smaller, easier and faster. It also allows
for easy customization (black border around the progress bar, maybe even
some fancy 3D effect, and if we are really cool, we can find out the
theme colors and draw the progress bar in the real theme colors. I can
help you with that, if you want.
The last time I did PyCairo and GTK theme stuff, it was really fun and
interesting (because you can do wonderful things with little cairo
code), so I won't take the task of messing a bit with cairo off you ;)
Enjoy,
Thomas
_______________________________________________
gpodder-devel mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/gpodder-devel
________________________________________________________________________
My...où ? You...quoi ? Face...qui ?... Vous ne savez plus comment être
vous-même ?
Pour Créer, Partager et enfin Gagner ... Découvrez iDOO en vidéo
http://www.idoo.com/fr/videomark.php
_______________________________________________
gpodder-devel mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/gpodder-devel