Re: GtkImageView




On Dec 19, 2007, at 4:13 PM, Jeffrey Ratcliffe wrote:

On 19/12/2007, muppet <scott asofyet org> wrote:
If that still doesn't work, give us the url of an svn branch that has
the current code.

I understand what you say, but I can't find a prototype for
SvDrawSettings (or for SvGtkStockItem in Gtk2/xs/GtkStock.xs).

I should stop writing emails with toddlers around.  ;-)

A C function definition doubles as a prototype. I should've said "signature" rather than "prototype." Sorry for the confusion.


I've committed what I have to SVN at
http://trac.bjourne.webfactional.com/browser/plgtkimageview/


I don't have a release version of gtkimageview handy, so this patch will build fine against the svn HEAD version of gtkimageview.

It replaces all the occurrences of DrawSettings with GdkPixbufDrawOpts; adds the new "rect" parameter to gtk_iimage_tool_pixbuf_changed(); adds the file gtkimageview.typemap instead of creating build/perl.typemap in Makefile.PL (don't forget to "svn add" it); and, the important bit, adds a cast to this line:

if (svp) settings->zoom_rect = * (GdkRectangle *) SvGdkRectangle (*svp);

to fix the "dereferencing `void *' pointer".

You'll also want to hush the "unused variable `class'" warning by not including the line "SV * class" in the argument listing of gtk_image_view_new().

I think the secondary "void value not ignored as it should be" warning was just fallout from the compiler being confused about the "void*" pointer dereference. (And, yes, i think we ought to change Glib::CodeGen to fix this upstream.)

Attachment: plgtkimageview-svn.patch
Description: Binary data





--
One, two, free, four, five, six, sebben, eight, nine, ten, elebben, twull, fourteen, sickteen, sebbenteen, eightteen, elebbenteen, fiffeen, elebbenteen!
  -- Zella, aged three, counting to twenty.




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