
--- Glynn Clements
David Sankel wrote: BTW, I'm curious as to what you were using 8 years ago; neither GTK nor Qt were around then.
Offtopic, but 8 years ago UNIX wasn't widely accessible. So I was stuck with either text based applications or winapi for the most part.
that this be an CGA implementation specific extension.
myButton <- newButton [ title := "Okay", i_name := "RightButton" ]
This would mean that a missing name would be a run-time error, when it should be caught at compile time.
How about myButton <- i_newButton "RightButton" [ title := "Okay" ] in accordance with my previous statements.
1. Records (with named fields) would be preferable to tuples; Some callbacks get passed a significant amount of data.
Can you give an example where a standard widget would pass a significant amount of data?
2. This approach requires a different function for each type of callback. I would prefer a single polymorphic addCallback function.
This is again making runtime errors into what could have been compile time errors. I think this is reason enough not to do it this way. Anyway, we can still use a single polymorphic addCallback function. instance HasAddCallback (Int,Int,Float) -- ... Cheers, David J. Sankel