hey dear helping hands,
I am still hunting for a good solution.
Lets sum it up again: I must be able to reference every single widget by an ID.
I must position and design an UI with, say 1000 widgets (actually the synth has
1900+ parameters, but Im not sure how many of them will require a widget yet).
I don't like to imagine how much work it is to do the UI-design all the way
manually (without FLUID).
ok,
I could create a new class for every widget used that contains getId/setID
methods. I don't like this approach as I have to ask every widget for it's ID
before I can change the correct one.
The array approach seems good IF i could somehow manage to add a reference of
every widget i add in FLUID into an array.
I mean: I would use FLUID to create the different windows and widgets, and tell
FLUID to also create a reference for this widget into array[XXX].
That way I could use FLUID freely (eg move widgets between windows if I like)
because the ID is stored "externally". I could access the values of every
widget without searching for it using the array.
Is it a good idea? How would I do that in FLUID?
I would need to use my own Classes in FLUID to design the UI, like this one:
//class Slider : public Fl_Slider, public Control {
//public:
// Slider(int x, int y, int w, int h, char const* label = 0)
// : Fl_Slider(x, y, w, h, label)
// {;} // what is this for?
// void set_value(int v) { Fl_Slider::value(v); }
// int get_value() const { return Fl_Slider::value(); }
so that i can use
ui->widget_array[id]->set_value(foo);
for all those widgets i use.
I doubt that this will work though. How would FLUID know about the available
parameters of my widgets? And how would i tell it to put a reference into eg
widget_array[130]?
What do you think?
Jan
_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk