Hi Maxime, Sorry for late, quite busy recently. :(
Maxime Henrion <mhenr...@gmail.com> writes: > Hello all, > > > I recently had to use a CheckMenuItem object in some gtk2hs code. I was > surprised to see that the documentation doesn't contain anything on the > "toggled" signal for this object. > > I resorted to use connectGeneric but that function is clearly very > unsafe. It seems to accept any type for the handler, and if you get it > wrong, you experience stack trashing and segfaults. In my case, trying > to use a plain IO action as the handler caused crashes; reading some > more code I prefixed it with "\_ ->" and it now works fine... I have add "toggle" signal in darcs. > > Furthermore, I had to also bind to the "row-activated" signal of the > TreeView object. Using onRowActivated works fine, however the > documentation marks it as deprecated, and doesn't offer any replacement > for it. Supposedly, that would be: > > rowActivated :: TreeViewClass self => Signal self (TreePath -> > TreeViewColumn -> IO ()) > > It seems to me that gtk2hs has moved onto using the "on" and "after" > combinators for handling signals, but that it still lacks replacements > for a fair number of old-style signal binding functions. Yes, we move noto 'on/after' signal, make API simpler. :) Unfortunately, not all old-style signal have convert to new style, Axel and me quite busy recently. Maxime, can you convert all old-style signals to new style if you have time? Thanks for report! :) -- Andy ------------------------------------------------------------------------------ Download new Adobe(R) Flash(R) Builder(TM) 4 The new Adobe(R) Flex(R) 4 and Flash(R) Builder(TM) 4 (formerly Flex(R) Builder(TM)) enable the development of rich applications that run across multiple browsers and platforms. Download your free trials today! http://p.sf.net/sfu/adobe-dev2dev _______________________________________________ Gtk2hs-devel mailing list Gtk2hs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gtk2hs-devel