1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-02-02 19:56:13 +01:00

Turn font sprite base into a strong enum

This commit is contained in:
Gymnasiast
2021-02-27 12:40:20 +01:00
parent 582037bbf3
commit 2477933c51
40 changed files with 149 additions and 138 deletions

View File

@@ -28,7 +28,7 @@ static InGameConsole _inGameConsole;
static int32_t InGameConsoleGetLineHeight()
{
auto fontSpriteBase = (gConfigInterface.console_small_font ? FONT_SPRITE_BASE_SMALL : FONT_SPRITE_BASE_MEDIUM);
auto fontSpriteBase = (gConfigInterface.console_small_font ? FontSpriteBase::SMALL : FontSpriteBase::MEDIUM);
return font_get_line_height(fontSpriteBase);
}
@@ -272,7 +272,7 @@ void InGameConsole::Draw(rct_drawpixelinfo* dpi) const
return;
// Set font
gCurrentFontSpriteBase = (gConfigInterface.console_small_font ? FONT_SPRITE_BASE_SMALL : FONT_SPRITE_BASE_MEDIUM);
gCurrentFontSpriteBase = (gConfigInterface.console_small_font ? FontSpriteBase::SMALL : FontSpriteBase::MEDIUM);
uint8_t textColour = NOT_TRANSLUCENT(ThemeGetColour(WC_CONSOLE, 1));
const int32_t lineHeight = InGameConsoleGetLineHeight();
const int32_t maxLines = GetNumVisibleLines();