#include <sglBitmapFont.hpp>
Inheritance diagram for sglBitmapFont::
Public Methods | |
sglBitmapFont () | |
virtual | ~sglBitmapFont () |
virtual sglBitmapFont* | clone () const=0 |
void | rasterString (const string &str) const |
virtual void | rasterString (const char *str, int len=-1) const=0 |
virtual unsigned int | getHeight () const=0 |
virtual unsigned int | getDescent () const=0 |
virtual unsigned int | getCharWidth (char c) const=0 |
virtual unsigned int | getStringWidth (const string &str) const |
Static Public Methods | |
void | setDefaultFont (sglBitmapFont *font) |
sglBitmapFont* | getDefaultFont () |
{\bf Example:}
\begin{verbatim} a subclass of sglBitmapFont specific to X11 sglBitmapFontGLX *fnt = NULL;
Display *dpy = glXGetCurrentDisplay(); XFontStruct *font = XLoadQueryFont(dpy, "fixed"); if (font) { sglBitmapFontGLX *fnt = new sglBitmapFontGLX(font->fid); fnt->rasterString("This is rendered at current raster position."); } \end{verbatim}
Definition at line 62 of file sglBitmapFont.hpp.
|
default constructor.
Definition at line 66 of file sglBitmapFont.hpp. |
|
destructor.
Definition at line 68 of file sglBitmapFont.hpp. |
|
Create a copy of this font. The copy will have display lists that are valid for the current context.
Reimplemented in sglBitmapFont8x13, and sglBitmapFontGLX. |
|
Renders a bitmap string at the current raster position. Characters should be limited to the ASCII range 0-127.
Definition at line 80 of file sglBitmapFont.hpp. |
|
Renders a bitmap string at the current raster position. Characters should be limited to the ASCII range 0-127.
Reimplemented in sglBitmapFont8x13, and sglBitmapFontGLX. |
|
Gets the height of the font in pixels.
Reimplemented in sglBitmapFont8x13, and sglBitmapFontGLX. |
|
Gets the extent of the font below the baseline in pixels.
Reimplemented in sglBitmapFont8x13, and sglBitmapFontGLX. |
|
Gets the width of the given character.
Reimplemented in sglBitmapFont8x13, and sglBitmapFontGLX. |
|
Gets the width of the given string.
Reimplemented in sglBitmapFontGLX. |
|
Sets the default font to be used by sgl.
|
|
Gets the default font used by sgl.
Definition at line 123 of file sglBitmapFont.hpp. |