[Haskell-cafe] Problem with Gtk2hs

Stefan O'Rear stefanor at cox.net
Sat Dec 8 16:08:22 EST 2007

On Sat, Dec 08, 2007 at 08:33:36PM +0000, Andrew Coppin wrote:
> I just spent the evening writing a library that's a thin layer over Gtk2hs. 
> It took an age to get it to compile, but eventually it worked. Yay!
> When I ran it, I got this:
> Test2: gtk/Graphics/UI/Gtk/Gdk/PixbufData.hs.pp:58:0: No instance nor 
> default method for class operation Data.Array.Base.getNumElements
> Er... wow.
> OK, at this point, I am completely stumped. Any hints?

That's pretty obviously a bug - Graphics.UI.Gtk.Gdk.PixbufData doesn't
fully implement the (M)Array class.

> (Also, the documentation for Graphics.UI.Gtk.Misc.DrawingArea suggests that 
> you may want to draw a Pixbuf using the pixbufRenderToDrawable function - 
> but GHC complains that this function doesn't exist. I had to use drawPixbuf 
> instead. Wow that has a lot of parameters... In particular, the final two 
> don't seem to be documented. Interesting. They're both 0 in the "fastdraw" 
> demo.)

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://www.haskell.org/pipermail/haskell-cafe/attachments/20071208/8fb4949d/attachment.bin

More information about the Haskell-Cafe mailing list