| 1 | /*********************************************************************** | 
|---|
| 2 |         TextFormatting | 
|---|
| 3 | ***********************************************************************/ | 
|---|
| 4 | enum TextFormatting | 
|---|
| 5 | { | 
|---|
| 6 |         LeftAligned, | 
|---|
| 7 |         RightAligned, | 
|---|
| 8 |         Centred, | 
|---|
| 9 |         Justified, | 
|---|
| 10 |         WordWrapLeftAligned, | 
|---|
| 11 |         WordWrapRightAligned, | 
|---|
| 12 |         WordWrapCentred, | 
|---|
| 13 |         WordWrapJustified | 
|---|
| 14 | }; | 
|---|
| 15 |  | 
|---|
| 16 |  | 
|---|
| 17 | /*********************************************************************** | 
|---|
| 18 |         Font | 
|---|
| 19 | ***********************************************************************/ | 
|---|
| 20 | class Font //: public PropertySet | 
|---|
| 21 | { | 
|---|
| 22 |         ////////////////////////////////////////////// | 
|---|
| 23 |         // PropertySet | 
|---|
| 24 |         void setProperty(string name, string value); | 
|---|
| 25 |         string getProperty(string name) const; | 
|---|
| 26 |         string getPropertyDefault(string name) const; | 
|---|
| 27 |         string getPropertyHelp(string name) const; | 
|---|
| 28 |  | 
|---|
| 29 |         bool isPropertyPresent(string name) const; | 
|---|
| 30 |         bool isPropertyDefault(string name) const; | 
|---|
| 31 |  | 
|---|
| 32 |     tolua_outside PropertyIterator ceguiLua_getPropertyIterator @ getPropertyIterator() const; | 
|---|
| 33 |  | 
|---|
| 34 |     static void setDefaultResourceGroup(string resourceGroup); | 
|---|
| 35 |     static string getDefaultResourceGroup(); | 
|---|
| 36 |  | 
|---|
| 37 |     void load (); | 
|---|
| 38 |  | 
|---|
| 39 |         bool isCodepointAvailable(unsigned long cp) const; | 
|---|
| 40 |  | 
|---|
| 41 |         void setNativeResolution(const Size& sz); | 
|---|
| 42 |         void notifyScreenResolution(const Size& sz); | 
|---|
| 43 |  | 
|---|
| 44 |         float getTextExtent(string text, float xscale=1); | 
|---|
| 45 |         float getLineSpacing(float yscale=1) const; | 
|---|
| 46 |         float getFontHeight(float yscale=1) const; | 
|---|
| 47 |  | 
|---|
| 48 |         unsigned long getCharAtPixel(string text, unsigned long start_char, float pixel, float xscale=1); | 
|---|
| 49 |         unsigned long getCharAtPixel(string text, float pixel, float xscale=1); | 
|---|
| 50 |  | 
|---|
| 51 |         unsigned long getFormattedLineCount(string text, const Rect& format_area, TextFormatting fmt, float xscale=1); | 
|---|
| 52 |         float getFormattedTextExtent(string text, const Rect& format_area, TextFormatting fmt, float xscale=1); | 
|---|
| 53 | }; | 
|---|