On Fri, 2007-08-31 at 17:40 +0200, Tamas K Papp wrote:
On Thu, Aug 30, 2007 at 10:58:40PM -0400, Joubert Nel wrote:
Hello Tamas,
I'm experimenting with the xlib-context and have modified lines 170 and 172 to set maxheight and maxwidth to a large number.
This allows the resulting Xlib window to be resizable.
Before I continue down this path, I'd like to know whether you are open to the idea of expanding xlib-context so that it can play host to an interactive UI, instead of only *presenting* graphics. I'm thinking about creating a mechanism for passing along Xlib events etc. to a code that consumes cl-cairo2.
In an application where the GUI is not a sideshow but the main feature, you would have a single event loop that orchestrates everything, including GUI management and whatever background processes you need. Plain vanilla Xlib is not really suitable for that, as it is a pain in the ass to program. That's why people came up with toolkits like Gtk or Qt. I would suggest that you familiarize yourself with the framework of your choice, and then ask on the appropriate mailing list (cairo list is a good place to start).
Yes, perhaps I wasn't explicit enough. I am building a widget toolkit that aims to be smaller in scope yet fundamentally more flexible than either Gtk or Qt. The ideas are taken from the WPF in the .NET Framework 3.0, which I know very well.
In other words, I would need to extend the xlib bits in cl-cairo2 so that my widget toolkit can consume lower-level events that Xlib would pass, e.g. mousedown, resize window, key down, etc.
Maybe I can help more if you tell us what it is you are trying to achieve (what kind of application etc). Do you have any prior experience with using any of the X toolkits?
So, I'm building a widget toolkit that aims to provide the bits I want from the WPF model, because its content model makes it easy for users to build new powerful controls that are composed of other controls and also do data and visual templating.
I have; however, I haven't found anything that has something like the powerful content model that WPF (on Windows - .NET Framework 3.0) does. None of these toolkits' project pages seem to indicate that they're going to move in this direction either.
I guess I'm trying to figure out which lower-level library I want to use for the drawing + low level events in X.
Joubert