Fix #11054: Prevent translation of currency codes.

Most languages stick with the 3-letter latin currency codes in the name
string, however some translations are... clever... and use the currency
symbol instead. Whilst this may look nice, it can cause issues with fonts
as some scripts have a specific limited set of fonts which do not include
these symbols.

Instead, hard code the currency code list and add it when drawing the
currency name.
This commit is contained in:
Peter Nelson
2023-06-23 00:11:11 +01:00
committed by PeterN
parent d42a78f3e8
commit 9dd9b8ec74
5 changed files with 114 additions and 115 deletions

View File

@@ -2710,6 +2710,7 @@ static ChangeInfoResult GlobalVarChangeInfo(uint gvid, int numinfo, int prop, By
if ((newone != STR_UNDEFINED) && (curidx < CURRENCY_END)) {
_currency_specs[curidx].name = newone;
_currency_specs[curidx].code.clear();
}
break;
}