summaryrefslogtreecommitdiffstats
path: root/src/render/Font.h
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/render/Font.h27
1 files changed, 18 insertions, 9 deletions
diff --git a/src/render/Font.h b/src/render/Font.h
index 4b2dda2b..05c367fb 100644
--- a/src/render/Font.h
+++ b/src/render/Font.h
@@ -37,6 +37,9 @@ struct CFontDetails
int nFlashTimer;
bool8 anonymous_23;
uint32 anonymous_25;
+ CRGBA outlineColor;
+ int bOutlineOn;
+ int line;
};
struct CFontRenderState
@@ -56,6 +59,9 @@ struct CFontRenderState
bool8 proportional;
bool8 anonymous_14;
int16 style;
+ int bOutlineOn;
+ int line;
+ bool8 rightJustify;
};
class CSprite2d;
@@ -64,10 +70,7 @@ enum {
FONT_BANK,
FONT_STANDARD,
FONT_HEADING,
-#ifdef MORE_LANGUAGES
- FONT_JAPANESE,
-#endif
- MAX_FONTS = FONT_HEADING
+ MAX_FONTS
};
enum {
@@ -123,9 +126,9 @@ class CFont
static uint8 LanguageSet;
static int32 Slot;
#else
- static int16 Size[MAX_FONTS][210];
+ static int16 Size[MAX_FONTS][419];
#endif
- static int16 NewLine;
+ static bool16 NewLine;
public:
static CSprite2d Sprite[MAX_FONTS];
static CFontDetails Details;
@@ -146,7 +149,6 @@ public:
static void PrintChar(float x, float y, wchar c);
static void PrintString(float x, float y, wchar *s);
#ifdef XBOX_SUBTITLES
- static void PrintStringFromBottom(float x, float y, wchar *str);
static void PrintOutlinedString(float x, float y, wchar *str, float outlineStrength, bool fromBottom, CRGBA outlineColor);
#endif
static int GetNumberLines(float xstart, float ystart, wchar *s);
@@ -157,7 +159,7 @@ public:
static void PrintString(float x, float y, uint32, wchar *start, wchar *end, float spwidth);
#endif
static void PrintStringFromBottom(float x, float y, wchar *str);
- static float GetCharacterWidth(wchar c);
+ static float GetCharacterWidth(wchar c, bool forceProportional = false);
static float GetCharacterSize(wchar c);
static float GetStringWidth(wchar *s, bool spaces = false);
#ifdef MORE_LANGUAGES
@@ -189,6 +191,7 @@ public:
static void SetBackgroundOff(void);
static void SetBackGroundOnlyTextOn(void);
static void SetBackGroundOnlyTextOff(void);
+ static void SetFlashOff(void);
static void SetPropOn(void);
static void SetPropOff(void);
static void SetFontStyle(int16 style);
@@ -198,8 +201,14 @@ public:
static void SetBackgroundColor(CRGBA col);
static void SetColor(CRGBA col);
static void SetDropColor(CRGBA col);
- static wchar FindNewCharacter(wchar c);
+
+ static void SetOutlineColor(CRGBA col);
+ static void SetOutlineOn(int on);
+ static void SetNewLineAdd(int line);
+
+ static int16 FindNewCharacter(int16 c);
static void FilterOutTokensFromString(wchar*);
+ static bool16 CheckNewLine(wchar *s);
#ifdef MORE_LANGUAGES
static void ReloadFonts(uint8 set);