On 10.12.2008, at 17:55, Roman Kantor wrote: > Michael Sweet wrote: > m trying to think of a situation where you might want these... >> >> Just to further muddy the waters, why not define 4 bits for the >> position (left/right/top/bottom) and *2* bits (instead of the >> current 1) for "inside" (FL_ALIGN_INSIDE_VERTICAL and >> FL_ALIGN_INSIDE_HORIZONTAL). >> >> That would allow for the following positions: >> >> X X X X X >> +-----------+ >> X|X X X|X >> | | >> X|X X X|X >> | | >> X|X X X|X >> +-----------+ >> X X X X X >> >> > > Yes, I like it. > > Other useful feature would be left/right alignment of the images, not > only top/bottom as it is now. This would be useful for the use of > Images > (including procedural drawing ones) as glyphs for various "OK", > "Cancel", "Return",... and other buttons on left/right side as it is > common for such buttons: > +------------------+ > | \ / | > | X Cancel | > | / \ | > +------------------| > > +------------------+ > | / | > | / Apply | > | \/ | > +------------------| > > It seems that all this will require more than 8 bits for align field.
FLTK2 solves this issue by allowing graphics inside any text. You can register any graphic design with a name and access it via @. So for example: @return; is the vector drawing on the return button, but you can also register an image named "check", so @check; would generate the checkmark. Your button label then would be "@check; OK" or "@check;\nOK" for side- by-side or icon-over-text... . No additional bits required. ---- http://robowerk.com/ _______________________________________________ fltk mailing list [email protected] http://lists.easysw.com/mailman/listinfo/fltk

