ANNOUNCE: X Haskell Bindings 0.2

I'd like to announce the 0.2.* series release of the X Haskell Bindings. This release, like the prior 0.1.* series focuses on making the API prettier. This does mean that there's a good chance this is a breaking release. Also, 0.2.* is based on the just-released version 1.4 of the XML descriptions of the X protocol. The goal of XHB is to provide a Haskell implementation of the X11 wire protocol, similar in spirit to the X protocol C-language Binding (XCB). On Hackage: http://hackage.haskell.org/cgi-bin/hackage-scripts/package/xhb New this release: In the core protocol, a lot of the fields which previously were of type 'Word8' or 'Word16' now have appropriate higher-level types. For example, in the type GetWindowAttributesReply, the 'class' field was previously of type 'Word16', and is now of type 'WindowClass,' and the 'all_event_masks' field was of type 'Word32' and is now of type '[EventMask]'. These improvements haven't made their way out to the extensions yet, but the code-generation machinery is now in place for this to happen as the information makes its way into the XML protocol description. Related projects: X C Bindings: http://xcb.freedesktop.org/ -Antoine

aslatter:
I'd like to announce the 0.2.* series release of the X Haskell Bindings. This release, like the prior 0.1.* series focuses on making the API prettier. This does mean that there's a good chance this is a breaking release. Also, 0.2.* is based on the just-released version 1.4 of the XML descriptions of the X protocol.
The goal of XHB is to provide a Haskell implementation of the X11 wire protocol, similar in spirit to the X protocol C-language Binding (XCB).
On Hackage: http://hackage.haskell.org/cgi-bin/hackage-scripts/package/xhb
Woo, well done! Here's an Arch Linux package, http://aur.archlinux.org/packages.php?ID=23765 -- Don

On Sun, Feb 22, 2009 at 2:08 AM, Antoine Latter
The goal of XHB is to provide a Haskell implementation of the X11 wire protocol, similar in spirit to the X protocol C-language Binding (XCB). [snip] Related projects:
X C Bindings: http://xcb.freedesktop.org/
I wonder how XHB is related to Xmonad, specially the need for compositing. Sorry if this is a dumb question :). Thanks, -- Felipe.

Felipe Lessa
On Sun, Feb 22, 2009 at 2:08 AM, Antoine Latter
wrote: The goal of XHB is to provide a Haskell implementation of the X11 wire protocol, similar in spirit to the X protocol C-language Binding (XCB). [snip] Related projects:
X C Bindings: http://xcb.freedesktop.org/
I wonder how XHB is related to Xmonad, specially the need for compositing. Sorry if this is a dumb question :).
It could be used for it. I once thought of hacking away on exactly that, but got demotivated by the fact that all that xlib code would have to be replaced (including xmonad-contrib). While nowadays xlib programs are compatible with xcb, because xlib itself is now based on xcb, the haskell xlib bindings aren't based on xhb... we'd need xcb bindings, which kinda defeats the purpose of xhb. Then there's of xcompmgr, which works fine enough for what I want to have, and I fail to come up with any useful application of compositing in a twm in addition to transparency for focus indication. OTOH, writing a separate compositing manager using xhb is certainly possible, fits better into the UNIX world, and would, most likely, be easily be snarfed into xmonad in case it's going to happen to be ported over to xhb. If you want to know how, have a look at the xcompmgr sources, it's straight forward. -- (c) this sig last receiving data processing entity. Inspect headers for copyright history. All rights reserved. Copying, hiring, renting, performance and/or quoting of this signature prohibited.

On Sun, Feb 22, 2009 at 11:58 AM, Achim Schneider
I once thought of hacking away on exactly that, but got demotivated by the fact that all that xlib code would have to be replaced (including xmonad-contrib). While nowadays xlib programs are compatible with xcb, because xlib itself is now based on xcb, the haskell xlib bindings aren't based on xhb... we'd need xcb bindings, which kinda defeats the purpose of xhb.
xlib is based on xcb in the sense that libxcb owns the conection, and xlib takes it when it wants it. This approach has recently been generalized, so it should be possible (in principle) for XHB to ride on top of libxcb in the same way: http://lists.freedesktop.org/archives/xcb/2008-March/003347.html But I haven't looked into this approach too deeply, though. Questions I don't have answers to: + How do I get events/errors back into Haskell-land? + How do I get my FFI bindings to xlib to cooperate in all of this? But it would be great if we could use native Haskell where we can, but still call into C-libs where we can't. Antoine
participants (4)
-
Achim Schneider
-
Antoine Latter
-
Don Stewart
-
Felipe Lessa