|
|
Le samedi 1 octobre 2022 à 02:45:54 UTC+2, roger a écrit :
Still not quite sure here. I checked the documentation (Color & Font functions) and could only find fl_font which seemed to be part of an fl_draw package. I expected calls for things like win2_flag1->textsize(11); ... but globally win2_flag1->labelsize(11); .......but globally etc...
Do they exist ?
I don't know what would be win2_flag1 in your mind.
Among possible things, there are : For any given pointer to n Fl_Widget (e.g., Fl_Button *) widget widget->labelsize(size); // sets the widget's label size widget->labelfont(fontnumber); // sets the widget's label font widget->labelcolor(color); // sets the widget's label color widget->label(text); // sets the widget's label text
But this applies to the given widget only.
Functions with effects on all widgets were described in my previous post. A key thing is these functions must be used before widgets are created. A simple way to achieve that is to begin your main() with fl_open_display(); // needs #include <FL/platform.H>
and then use the global-effect function calls or change the value of public global variables.
--
You received this message because you are subscribed to the Google Groups "fltk.general" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fltkgeneral+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/fltkgeneral/109eb1bd-fecd-4f8e-b7bb-a00e2c72193an%40googlegroups.com.
[ Direct Link to Message ] | |
|
| |