
I am trying to load a bitmap and display it with the Xlib bindings, but I wasn't able to find a way. The C Xlib functions would be XReadBitmapFile() of XReadBitmapFileData() to read the data, but it seems that those functions haven't been included in the haskell bindings. From http://hackage.haskell.org/packages/archive/X11/latest/doc/html/src/Graphics...: -- XCreateBitmapFromData omitted (awkward looking type) -- XReadBitmapFileData omitted (awkward looking type) Does anybody know how to do that?

Francesco Mazzoli

On 31 January 2011 21:40, Francesco Mazzoli
Francesco Mazzoli
writes: At the end I gave up and I wrote the function myself:
cool ... the listed maintainer for the Xlib bindings is libraries@haskell.org. Perhaps you could prepare a patch and send it there? (does anyone know if there is an actual maintainer?) Conrad.

Conrad Parker
On 31 January 2011 21:40, Francesco Mazzoli
wrote: Francesco Mazzoli
writes: At the end I gave up and I wrote the function myself:
cool ... the listed maintainer for the Xlib bindings is libraries <at> haskell.org. Perhaps you could prepare a patch and send it there? (does anyone know if there is an actual maintainer?)
Conrad.
I will send a patch, but I'm sure there must be a reason behind the fact that those functions were not included, even if I can't see it. Francesco.

-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 2/2/11 04:03 , Francesco Mazzoli wrote:
Conrad Parker
writes: On 31 January 2011 21:40, Francesco Mazzoli
wrote: Francesco Mazzoli
writes: At the end I gave up and I wrote the function myself: http://hpaste.org/43464/readbitmapfile cool ... the listed maintainer for the Xlib bindings is libraries <at> haskell.org. Perhaps you could prepare a patch and send it there? (does anyone know if there is an actual maintainer?)
I will send a patch, but I'm sure there must be a reason behind the fact that those functions were not included, even if I can't see it.
Pretty much what the comment says. Graphics.X11 was never really a complete set of bindings, just what people needed at the time. The "Extras" stuff in there was driven by xmonad development, for example (and named so because originally it was a separate library before it got folded in, so the module names were difficult to change while maintaining compatibility). Dealing with structs in the FFI is painful enough that I can easily imagine someone saying "we don't need those, let someone else figure it out" --- which you have done. Patch away. - -- brandon s. allbery [linux,solaris,freebsd,perl] allbery@kf8nh.com system administrator [openafs,heimdal,too many hats] allbery@ece.cmu.edu electrical and computer engineering, carnegie mellon university KF8NH -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (Darwin) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk1Jq9cACgkQIn7hlCsL25XaJgCfc+CCngSmZlL9JOeZ21vZwkBO BHkAn128z1dH2entJKEfH6pKJ2Y7qW4w =LOMj -----END PGP SIGNATURE-----
participants (3)
-
Brandon S Allbery KF8NH
-
Conrad Parker
-
Francesco Mazzoli