1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-17 03:53:07 +01:00

Change gfx_draw_string_*_wrapped() to DrawTextWrapped()

This commit is contained in:
Gymnasiast
2021-02-27 17:17:17 +01:00
parent e2ebc9d43b
commit 3e536e2711
25 changed files with 97 additions and 102 deletions

View File

@@ -204,13 +204,14 @@ public:
if (_descriptionStringId == STR_NONE)
{
auto* text = _description.c_str();
gfx_draw_string_centred_wrapped(&dpi, &text, { windowPos.x + WW / 2, screenCoords.y }, WW, STR_STRING, colours[1]);
DrawTextWrapped(
&dpi, { windowPos.x + WW / 2, screenCoords.y }, WW, STR_STRING, &text, { colours[1], TextAlignment::CENTRE });
}
else
{
gfx_draw_string_centred_wrapped(
&dpi, &TextInputDescriptionArgs, { windowPos.x + WW / 2, screenCoords.y }, WW, _descriptionStringId,
colours[1]);
DrawTextWrapped(
&dpi, { windowPos.x + WW / 2, screenCoords.y }, WW, _descriptionStringId, &TextInputDescriptionArgs,
{ colours[1], TextAlignment::CENTRE });
}
screenCoords.y += 25;