FLTK-MT - a collection of widgets for FLTK
Author and collector: Matevz Tadel
FLTK-MT is supposed to work with FLTK-1.1. See http://www.fltk.org/.
Most of the widgets are abstractions of the stuff that I needed.
Some widgets were ruthlessly stolen from fltk-bazaar. The copyrights in sources are left intact (none prohibits further redistribution) and credits are given for each widget (or widget group).
FILES: Fl_SWM.*
CLASSES: Fl_Scaled_Windows_Manager, Fl_SWM_Client
STRUCTS: SWM_Size_Range
For dumb window layouts based upon character width/height it is often desirable to change font size of some group of windows. One such window has to inherit from Fl_SWM_Client and it should be initially constructed in ``character'' coordinates (think dumb terminal). Then it should be adopted by some manager and at that moment it is resized in accordance with manager's current fontsize and other size parameters (extra vertical skip and unit width (width of 'X'+2 by default)).
FILES: Fl_MC_Widget.H
CLASSES: template<class T_Widget=Fl_Widget> class Fl_MC_Widget :
public T_Widget
STRUCTS: Fl_MEVT
Templated extension of any widget. Overrides handle method and allows for an efficient callback mechanism for mouse events combined with modifier keys. For other events (and possibly also for some mouse events) the control is passed to the original handle method.
On the other hand ... this seems like a lot of crap.
FILES: Fl_File_Name.*
CLASSES: Fl_File_Name
Fl_File_Name is just extension of a Fl_Input. Mouse-3 pops up a modal file selector using fl_file_chooser().
Modality sucks! Fl_File_Chooser creates all windows privately and sets modal on.
Ideally, Fl_File_Name would hold a static list of registered, fully configured Fl_File_Chooser-s. Right-drag would then offer a selection of them and set the last selected as default for next right-click.
Filter-out on File_Chooser would come handy, too.
FILES: Fl_RelGroup.*
CLASSES: Fl_RelGroup
Just a wrapper for Fl_Group ... makes positions of all its children relative to the position of the group (like Fl_Window). I think this is the default for fltk-2.
Recently noticed strange behaviour. (After fltk-1.0.7, but haven't got around to investigate the problem. Sorry ... )
FILES: Fl_ScrollPack.*
CLASSES: Fl_ScrollPack
USES: Fl_SWM
EXAMPLE: scrollpack
Just a Scroll with a vertical Pack inside.
FILES: Fl_OutputPack.*
CLASSES: Fl_OutputPack
USES: Fl_SWM
EXAMPLE: outputpack
FILES: Fl_Widget_Labeler.*
CLASSES: Fl_Widget_Labeler
EXAMPLE: widget_labeler, scrollpack, swm
Fltk widgets have static labels. That is ... you're supposed to
allocate space for them if you are creating them on the
fly. Fl_Widget_Labeler allocates memory as needed in chunks (defaults
to 4K). Fl_Widget_Labeler::label_widget(Fl_Widget*, const char*)
copies a string to this buffer and sets widget label. Upon
destruction the allocated chunks are released.
Fl_Widget_Labeler::labelf_widget(Fl_Widget* w, const char* fmt,
...)
works as printf
family.
Labels are truncated if longer than chunk size.
FILES: Fl_RGBA_Button.*, Fl_RGBA_Chooser.*
CLASSES: Fl_RGBA_Button, Fl_RGBA_Chooser
USES: Fl_SWM
(optional)
ORIGIN: Matthias Melcher, Fltk-Bazaar. No license.
FILES: Fl_LED_Button.*
CLASSES: Fl_LED_Button
ORIGIN: Yves Usson, Fltk-Bazaar. No license.