Quote:Writing the GUI is always a tedious process, so I'd like to share as much of the code as possible.
Yes it is... I have written 2 GUI libs in past, one of them being especially complicated, and found it
really tedious and boring at times. However, the ability to develop UI for games with very little work absolutely recompensed my efforts.
OrangyTang, have you thought about writing this kind of library not only for you, but also for other people? I ask, since I am really interested in writing one open-source / portable / C++ / flexible / rather simple / GUI library for game programmers, and it would be good to work together.
You may say that there are literally thousends of other GUI libraries out there on the internet, so why won't you join them or start your own? The facts are, your design is very similar to what I thought about how my next GUI lib should look like. So, are you interested in creating such "general purpose" (but not too general, ie. kitchen sink not included) GUI library with me (at least, since Deffer was also interested in writing one with me). I applied for Google Summer of Code 2005 with my "GUI library targeted at game programming", but was rejected (probably due to the fact, that Blender group didn't want such useless thing coded for them ;-) ) and from that time, had no time to start working on it on my own (uni, other projects etc. take time), but I am still very interested in writing one.
Anyway, my comments about your lib:
+ add: XML used for storing widget properties
+ add: WYSIWYG layout editor which allows to drag n' drop controls, edit properties etc.; I found that having even very simple layout editor makes implementing UI much easier task; what's more, it could be implemented using this GUI
+ it's good you don't want to implement automatic layout packers - I found them rather useless for games, since usually you DO want to have
absolute control of your widgets
+ things to strive for: flexibility, RAD, ease of use (for developer), portability
+ flexibility: easy way to add new controls (ie. specific to game), ability to subclass other ones
+ abstract interface for every used external library, so that they can be easily changed to others (ie. SDL render things too slow for you, so you write OpenGL plugin)
+ skins
+ add: resolution independent control positioning / scaling!
- missing widgets: floating windows, drop-down lists, key binders
- I second Telastyn - adding the right-click ability is next to trivial, but it does have some very interesting effects
? you didn't write anything about communication GUI <-> programmer... callbacks, generic functors, sockets and signals or what?