]> gitweb.factorcode.org Git - factor.git/commitdiff
gdk.pixbuf: workaround for an incorrect return-value in .gir for gdk_pixbuf_get_pixel...
authorAnton Gorenko <ex.rzrjck@gmail.com>
Tue, 30 Aug 2011 16:12:42 +0000 (22:12 +0600)
committerAnton Gorenko <ex.rzrjck@gmail.com>
Tue, 30 Aug 2011 16:12:42 +0000 (22:12 +0600)
basis/gdk/pixbuf/ffi/ffi.factor

index 79c9cb8a3506bc6824b178b02b08d3c778ac3559..d60da8fbc05b739989c98e44462985679d17d8c3 100644 (file)
@@ -1,12 +1,14 @@
 ! Copyright (C) 2010 Anton Gorenko.
 ! See http://factorcode.org/license.txt for BSD license.
 USING: alien alien.data alien.libraries alien.syntax
-combinators gio.ffi glib.ffi gmodule.ffi gobject-introspection
-gobject.ffi kernel libc sequences system vocabs.loader ;
-EXCLUDE: alien.c-types => pointer ;
+combinators gio.ffi glib.ffi gobject-introspection
+gobject-introspection.standard-types kernel libc
+sequences system vocabs.loader ;
 IN: gdk.pixbuf.ffi
 
+<<
 "gio.ffi" require
+>>
 
 LIBRARY: gdk.pixbuf
 
@@ -19,6 +21,13 @@ LIBRARY: gdk.pixbuf
 
 GIR: vocab:gdk/pixbuf/GdkPixbuf-2.0.gir
 
+! <workaround incorrect return-value in gir
+
+FORGET: gdk_pixbuf_get_pixels
+FUNCTION: guint8* gdk_pixbuf_get_pixels ( GdkPixbuf* pixbuf ) ;
+
+! workaround>
+
 : data>GInputStream ( data -- GInputStream )
     [ malloc-byte-array &free ] [ length ] bi
     f g_memory_input_stream_new_from_data ;