gdk_pixbuf and comments ?



Hi,

we'd like to switch to PNG image thumbnails for the next version of 
The GIMP (we will include .xvpics loading for backward compatibility 
of course). I've started to hack on this today and found no way to 
retrieve a comment from a GdkPixbufLoader. The xvpics format has 
sort of a comment field and we use it to store information as 
"1600x1200 RGB (23532 bytes)" that we display in the file open dialog.
I do like the idea of using gdk-pixbuf to load and write the thumbnails
but I wouldn't like to drop the feature of including some extra 
information with the thumbnail. 

Would you object against the addition of a (gchar *) comment field to 
a GdkPixbuf? The load and write routines would have to be extended to 
handle this data, but I doubt it would be much of a hassle since all 
the loaders already have to deal with comment fields in the files. I'm 
asking for your opinion first, but would try to create a patch if you 
like it. Alternatively we could add a comment field to GdkPixbufLoader 
and provide a way to add a comment when using gdk_pixbuf_save(). This
way we wouldn't increase the overhead of GdkPixbuf, but the API would
be considerably more difficult.


Salut, Sven




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]