#include <font_ftgl.h>
Inherits Font.
Inheritance diagram for FontFTGL:


Public Member Functions | |
| FontFTGL (const char *file, int ptsize) | |
| Construct font. | |
| virtual | ~FontFTGL () |
| Destroy allocated font. | |
| virtual void | RenderUTF8 (const std::string &utf8str, float x, float y) |
| Render utf-8 encoded text. | |
| virtual int | Ascent () |
| Get line height. | |
| virtual int | getTextWidth (const std::string &utf8str)=0 |
| Render some text in 3D.Get With of text in pixels. | |
| virtual int | getWwidth ()=0 |
| Get width of W. | |
Private Attributes | |
| FTGLPixmapFont * | mFont |
| FTGL font structure. | |
This was first try of font. The implementation is without any kind of cache. Don't expect high performance, but it works.
Definition at line 20 of file font_ftgl.h.
|
||||||||||||
|
Construct font. Program is killed if contruction fails.
Definition at line 15 of file font_ftgl.cpp. References DIE(), LOGE, and mFont. Here is the call graph for this function: ![]() |
|
|
Destroy allocated font.
Definition at line 28 of file font_ftgl.cpp. References mFont. |
|
|
Get line height. The value is usefull if you want to render multiline text and need to know height of line.
Implements Font. Definition at line 52 of file font_ftgl.cpp. |
|
|
Render some text in 3D.Get With of text in pixels. Get width of utf-8 encoded text.
Implements Font. |
|
|
Get width of W. W is usuallu the most width char in font so you may use this as aproximation.
Implements Font. |
|
||||||||||||||||
|
Render utf-8 encoded text. This function must be called in 2D opengl mode.
Implements Font. Definition at line 37 of file font_ftgl.cpp. References assertL, mFont, TIN, and utf8tows(). Here is the call graph for this function: ![]() |
|
|
FTGL font structure.
Definition at line 64 of file font_ftgl.h. Referenced by Ascent(), FontFTGL(), RenderUTF8(), and ~FontFTGL(). |
1.4.5