[gpodder-devel] Proposition: progress bar on the tray icon

  • From: jerome.chabod at ifrance.com (jerome.chabod at ifrance.com)
  • Date: Fri, 22 Feb 2008 08:42:03 +0100

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 : thp at perli.net
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
 gpodder-devel at lists.berlios.de
 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
-------------- next part --------------
An HTML attachment was scrubbed...
URL: 
<https://lists.berlios.de/pipermail/gpodder-devel/attachments/20080222/c7812c66/attachment.html>

Other related posts: