[pygtk] pygtk svg image problem...
kourem at gmail.com
Wed Mar 30 19:10:20 WST 2005
On Wed, 30 Mar 2005 15:07:22 +0500, Muhammad Ali <ali.jan at gmail.com> wrote:
> Hi everyone,
> I am running python 2.4 with pygtk version 2, 4, 1. I am trying to
> open an svg image in a gtk.Image. I am getting the following error:
> gobject.GError: Couldn't recognize the image file format for file
> First I tried with the set_from_file method of Image but it would show
> a broken image icon with on error so then i tried
> pic = gtk.gdk.pixbuf_new_from_file(fullname)
> which is now showing me the above error... any ideas as to what the
> problem could be?
AFAIK, you *can't* use svg in gtk.Image atm
you need bindings to rsvg
Mono has done some work in this area, not sure what python has done
what happend to http://www.daa.com.au/pipermail/pygtk/2003-October/006088.html ?
atm I suggest you just png it via gimp in a large resolution if that's
your problem and you can resize it via gtk to smaller
Reference should say the types a gtkImage support [and in pixbuf]
tutorial says some stuff but says etc..!
tutorial also needs to get a gtk.TRUE/FALSE --> True/False with sed
Nikos Kouremenos | Jabber ID: nkour at jabber.org | http://members.hellug.gr/nkour
More information about the pygtk