mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-27 00:34:46 +01:00
Update members of FontStyle
This commit is contained in:
@@ -729,7 +729,7 @@ void CustomListView::PaintSeparator(RenderTarget& rt, const ScreenCoordsXY& pos,
|
||||
// Get string dimensions
|
||||
utf8 stringBuffer[512]{};
|
||||
FormatStringLegacy(stringBuffer, sizeof(stringBuffer), STR_STRING, ft.Data());
|
||||
int32_t categoryStringHalfWidth = (GfxGetStringWidth(stringBuffer, FontStyle::Medium) / 2) + 4;
|
||||
int32_t categoryStringHalfWidth = (GfxGetStringWidth(stringBuffer, FontStyle::medium) / 2) + 4;
|
||||
int32_t strLeft = centreX - categoryStringHalfWidth;
|
||||
int32_t strRight = centreX + categoryStringHalfWidth;
|
||||
|
||||
|
||||
@@ -159,8 +159,8 @@ namespace OpenRCT2::Scripting
|
||||
|
||||
DukValue measureText(const std::string& text)
|
||||
{
|
||||
auto width = GfxGetStringWidth(text, FontStyle::Medium);
|
||||
auto height = StringGetHeightRaw(text.c_str(), FontStyle::Medium);
|
||||
auto width = GfxGetStringWidth(text, FontStyle::medium);
|
||||
auto height = StringGetHeightRaw(text.c_str(), FontStyle::medium);
|
||||
return ToDuk<ScreenSize>(_ctx, { width, height });
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user