Dynamically creating gui objects on demand in Perl
Jun 12, 2009, 15:02 (0 Talkback[s])
Full Text Search: The Key to Better Natural Language Queries for NoSQL in Node.js
[ Thanks to j00p34 for this link.
"Dynamic checkbox creation
"I also created a box which contained checkboxes for a few of
the options of the ls command. As I want to add more commands to
the tool it would take me a lot of time to create all the
checkboxes and a lot of copy pasting code. I don't think that's a
good idea, so I've been thinking of some way of dynamically
creating vertical boxes containing the checkboxes for all options
per command. That way I can just create a VBOX by passing a command
and it's options to a subroutine.
"This is possible because the Gtk library is object oriented, so
I can create objects in my subroutine and pass them back. I think
I'm going to do something like subclassing the Vbox class in the
future, at this moment I don't have a clue how to accomplish such a
thing. For now I'll just start with some kind of proof of concept
code. In my previous article I got to version 7 of the program so
here I'll start with version 8."