From 8a9ffb303198d228ef031a386360a74f850809a9 Mon Sep 17 00:00:00 2001 From: drfrag Date: Wed, 10 Apr 2019 16:19:41 +0200 Subject: [PATCH] =?UTF-8?q?-=20added=20a=20fallback=20mapping=20for=20the?= =?UTF-8?q?=20typographic=20upper=20quotation=20mark=20to=20the=20generic?= =?UTF-8?q?=20form.=20-=20added=20lowercase->uppercase=20mapping=20for=20?= =?UTF-8?q?=C3=9F.=20(patch=20by=20Graf)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/v_font.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/v_font.cpp b/src/v_font.cpp index d1453d259..01bba067e 100644 --- a/src/v_font.cpp +++ b/src/v_font.cpp @@ -286,6 +286,7 @@ static const uint16_t loweruppercase[] = { 0x0078,0x0058, 0x0079,0x0059, 0x007A,0x005A, +0x00DF,0x1E9E, 0x00E0,0x00C0, 0x00E1,0x00C1, 0x00E2,0x00C2, @@ -1011,7 +1012,12 @@ static int stripaccent(int code) static const uint16_t u200map[] = {0xc4, 0xe4, 0xc2, 0xe2, 0xcb, 0xeb, 0xca, 0xea, 0xcf, 0xef, 0xce, 0xee, 0xd6, 0xf6, 0xd4, 0xe4, 'R', 'r', 'R', 'r', 0xdc, 0xfc, 0xdb, 0xfb, 0x15e, 0x15f, 0x162, 0x163}; return u200map[code - 0x200]; } - + else if (code == 0x201d) + { + // Map the typographic upper quotation mark to the generic form + code = '"'; + } + // skip the rest of Latin characters because none of them are relevant for modern languages. return code;