Rev | Line | |
---|
[4597] | 1 | /*! |
---|
[5039] | 2 | * @file text_engine.h |
---|
[5347] | 3 | * Definition of textEngine, the Font and the Text |
---|
| 4 | * |
---|
| 5 | * Text is the text outputed. |
---|
| 6 | * Font is a class that loads a certain ttf-file with a specific height into memory |
---|
| 7 | * TextEngine is used to manage the all the different Fonts that might be included |
---|
| 8 | * |
---|
| 9 | * for more information see the specific classes. |
---|
| 10 | * |
---|
| 11 | * !! IMPORTANT !! When using ttf fonts clear the license issues prior to |
---|
| 12 | * adding them to orxonox. This is really important, because we do not want |
---|
| 13 | * to offend anyone. |
---|
| 14 | */ |
---|
[3766] | 15 | |
---|
| 16 | #ifndef _TEXT_ENGINE_H |
---|
| 17 | #define _TEXT_ENGINE_H |
---|
[3655] | 18 | |
---|
| 19 | #include "base_object.h" |
---|
| 20 | |
---|
[3766] | 21 | // FORWARD DECLARATION |
---|
[3655] | 22 | |
---|
[5347] | 23 | //! A singleton Class that operates as a Handler initializing FONTS. |
---|
[4597] | 24 | class TextEngine : public BaseObject |
---|
[3773] | 25 | { |
---|
[9869] | 26 | ObjectListDeclaration(TextEngine); |
---|
| 27 | public: |
---|
[4746] | 28 | virtual ~TextEngine(); |
---|
[4836] | 29 | /** @returns a Pointer to the only object of this Class */ |
---|
[4746] | 30 | inline static TextEngine* getInstance() { if (!singletonRef) singletonRef = new TextEngine(); return singletonRef; }; |
---|
[3766] | 31 | |
---|
[4746] | 32 | void debug() const; |
---|
[3774] | 33 | |
---|
[3769] | 34 | private: |
---|
[4746] | 35 | TextEngine(); |
---|
[3769] | 36 | static TextEngine* singletonRef; |
---|
| 37 | |
---|
[3766] | 38 | // general |
---|
[4746] | 39 | static void enableFonts(); |
---|
| 40 | static void disableFonts(); |
---|
| 41 | static bool checkVersion(); |
---|
[3766] | 42 | }; |
---|
| 43 | |
---|
| 44 | #endif /* _TEXT_ENGINE_H */ |
---|
Note: See
TracBrowser
for help on using the repository browser.