> Ya, that's a cool trick. I keep forgetting it myself. Yes indeed, really cool! I tend to modify fltk code scaling it manually or to hardcode full font name with size via set_font(). Ah, there is always simplier solution :)
> It's something of a 'workaround' for this STR item: > http://fltk.org/str.php?L1029 > I'm still +1 on the idea of making an official Fl::XXX() method > for not only setting the default font face/size, but also a way > to apply an 'offset size' to all fonts, eg. Fl::fontsize_offset(4); > which could add 4 points to the font size of all fonts. +1 for both. > I /think/ it might be easy to: > > 1) Add a 'font size offset' global, > > 2) modify the text drawing routines to dynamically add that > value to the > current fl_size() on the fly to calculate the actual drawing > size. > > ..at least, that's how I'd 'hack' it in there. There might be a cleaner > way to do this though, not sure. > > That technique is also a /little/ unclean, because it means calls to > int fl_font(void) wouldn't return the actual font size being drawn, > which might mess up things like font measuring, and whatnot, unless that > too includes the new 'font offset'. Or: 3) fl_font() could return actual font size plus font offset where real font size could be extracted via fl_font() - fl_font_offset(); this saves a lot of messing with existing code -- Sanel _______________________________________________ fltk mailing list [email protected] http://lists.easysw.com/mailman/listinfo/fltk

