Browse Source

Documentation: clarification of fl_width()'s dependence on the current font face/size.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10320 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
pull/49/head
Greg Ercolano 11 years ago
parent
commit
d5698e8ed9
  1. 9
      FL/fl_draw.H

9
FL/fl_draw.H

@ -531,11 +531,14 @@ FL_EXPORT int fl_height(int font, int size);
draw the text at so it looks centered vertically in that box. draw the text at so it looks centered vertically in that box.
*/ */
inline int fl_descent() {return fl_graphics_driver->descent();} inline int fl_descent() {return fl_graphics_driver->descent();}
/** Returns the typographical width of a nul-terminated string */ /** Returns the typographical width of a nul-terminated string
using the current font face and size. */
FL_EXPORT double fl_width(const char* txt); FL_EXPORT double fl_width(const char* txt);
/** Returns the typographical width of a sequence of \p n characters */ /** Returns the typographical width of a sequence of \p n characters
using the current font face and size. */
inline double fl_width(const char* txt, int n) {return fl_graphics_driver->width(txt, n);} inline double fl_width(const char* txt, int n) {return fl_graphics_driver->width(txt, n);}
/** Returns the typographical width of a single character. /** Returns the typographical width of a single character
using the current font face and size.
\note if a valid fl_gc is NOT found then it uses the first window gc, \note if a valid fl_gc is NOT found then it uses the first window gc,
or the screen gc if no fltk window is available when called. */ or the screen gc if no fltk window is available when called. */
inline double fl_width(unsigned int c) {return fl_graphics_driver->width(c);} inline double fl_width(unsigned int c) {return fl_graphics_driver->width(c);}

Loading…
Cancel
Save