> How do you want to treat windows, that have a fixed part, developed with
> glade, and a variable part, defined at run time with a configuration file?
I don't know how many programs actually create widgets on the fly (
report/form generators come to mind ), but in that case you have a few
options:
1. Maintain a hashtable of widget names to widgets using g_hash_table.
2. Just include lookup_widget yourself.
I am not saying that there is no value to a lookup_widget function. I am
saying that I find it easier to program a gui when the names/types of
widgets are predefined. Having the widgets stored as pointers to their type
(GtkButton, GtkLabel,...) means that you don't have lots of unnecessary
calls to lookup_widget plus a caste. That not only adds more code, but
slows down the gui. You can implement it however you want! Nothing I am
doing will stop you from using the old methods. I am just providing an
alternative that appeals more to *me*.
> With lookup_widget it's easy, but with your solution, that I know from
XForms,
> it's not so easy.
I've never used XForms, so I can't really comment.
> Lookup_widget only looks for widgets in one (top-level)-window. So there
> is now problem to call all "OK"-buttons ok_button.
Sorry, you're right.
> Don't say anything against EMACS. I'm using it since the good old days of
> Multics-Emacs in 1984 and I really love it!!!
I love it too, but I still hate the way you have to go through hundreds of
options just to find the one that does what you want. Emacs is powerful
because of its ability to be configured ten ways to Sunday. Emacs is
scorned by some because of the number of key sequences needed to use its
features. ALT-META-CTRL-D-% and such... :)
I just want to make it clear that this is not a pissing contest. My ideas
are based on my experiences of what works best for ME. I can't predict how
users will respond to my ideas, but then the user has the choice to modify
the way I do it. Programmers are a diverse group and rarely agree on the
technical details of an implementation. Code generaters are necessarily
sticky points with developers because if the code doesn't look just right...
With open source, however, you can have your cake and eat it too! The code
I write will be available under GPL, so make modifications as you see fit!
I will try my best to make the code capable of generating a variety of code
constructs so that if you want lookup_widget calls, you can have them!
I opened up a SourceForge project called g2c (glade to C). I will be adding
some design documentation shortly, so you can keep up to date on my
progress. Help is always appreciated, but if you just want to comment on
the design, you can use the public forums linked to on that page.
John
+---------------------------------------------------------------------+
To unsubscribe from this list, send a message to [EMAIL PROTECTED]
with the line "unsubscribe glade-devel" in the body of the message.