From fd12aff8f72fca96ae25f30db2a376d5aff1e9a4 Mon Sep 17 00:00:00 2001 From: Michael Steenbeek Date: Sun, 23 Sep 2018 22:23:37 +0200 Subject: [PATCH] Add D and E with caron This also adds the Unicode codepoints for the remaining Czech letters. --- resources/g2/font/latin/d-caron-bold.png | Bin 0 -> 185 bytes resources/g2/font/latin/d-caron-small.png | Bin 0 -> 180 bytes resources/g2/font/latin/d-caron-tiny.png | Bin 0 -> 177 bytes resources/g2/font/latin/d-caron-uc-bold.png | Bin 0 -> 193 bytes resources/g2/font/latin/d-caron-uc-small.png | Bin 0 -> 178 bytes resources/g2/font/latin/d-caron-uc-tiny.png | Bin 0 -> 172 bytes resources/g2/font/latin/e-caron-bold.png | Bin 0 -> 179 bytes resources/g2/font/latin/e-caron-small.png | Bin 0 -> 178 bytes resources/g2/font/latin/e-caron-tiny.png | Bin 0 -> 172 bytes resources/g2/font/latin/e-caron-uc-bold.png | Bin 0 -> 180 bytes resources/g2/font/latin/e-caron-uc-small.png | Bin 0 -> 182 bytes resources/g2/font/latin/e-caron-uc-tiny.png | Bin 0 -> 170 bytes resources/g2/sprites.json | 72 +++++++++++++++++++ src/openrct2/drawing/Font.cpp | 4 ++ src/openrct2/localisation/FormatCodes.h | 16 +++++ src/openrct2/sprites.h | 7 +- 16 files changed, 98 insertions(+), 1 deletion(-) create mode 100644 resources/g2/font/latin/d-caron-bold.png create mode 100644 resources/g2/font/latin/d-caron-small.png create mode 100644 resources/g2/font/latin/d-caron-tiny.png create mode 100644 resources/g2/font/latin/d-caron-uc-bold.png create mode 100644 resources/g2/font/latin/d-caron-uc-small.png create mode 100644 resources/g2/font/latin/d-caron-uc-tiny.png create mode 100644 resources/g2/font/latin/e-caron-bold.png create mode 100644 resources/g2/font/latin/e-caron-small.png create mode 100644 resources/g2/font/latin/e-caron-tiny.png create mode 100644 resources/g2/font/latin/e-caron-uc-bold.png create mode 100644 resources/g2/font/latin/e-caron-uc-small.png create mode 100644 resources/g2/font/latin/e-caron-uc-tiny.png diff --git a/resources/g2/font/latin/d-caron-bold.png b/resources/g2/font/latin/d-caron-bold.png new file mode 100644 index 0000000000000000000000000000000000000000..b6e01404e009c7e58c2b07d57dd06e42a4f108f5 GIT binary patch literal 185 zcmeAS@N?(olHy`uVBq!ia0y~yVBln6VBlh6W?*2D&Yq*oz`(#0;1lASs+-=y@c%zU zhq3Yh_P>8)7#J8BOM?7@862M7NCR<_yxmdJL>4nJa0`PlBg3pY5)2Fs z>?NMQuI!IES%n0JQ-i1PVqjoU^K@|x;kcfh5OL(d0g>v4M(&Q##)>E#=EGYgIOcI3 hS>*46d8GBtp0) de(*CeWZ1Cp$@o^4!N9=4;OXk;vd$@?2>>(bF0uds literal 0 HcmV?d00001 diff --git a/resources/g2/font/latin/d-caron-tiny.png b/resources/g2/font/latin/d-caron-tiny.png new file mode 100644 index 0000000000000000000000000000000000000000..821274f56a3a7866356516b0e9d4cdd55244cd79 GIT binary patch literal 177 zcmeAS@N?(olHy`uVBq!ia0y~yU|#5htq=GgT1|N(W7)*At W#-CW#<;lRnz~JfX=d#Wzp$PzxS1#26 literal 0 HcmV?d00001 diff --git a/resources/g2/font/latin/d-caron-uc-bold.png b/resources/g2/font/latin/d-caron-uc-bold.png new file mode 100644 index 0000000000000000000000000000000000000000..86723aa1657ef7436f5545b514e6d83ec4de99b6 GIT binary patch literal 193 zcmeAS@N?(olHy`uVBq!ia0y~yVBln6VBltAW?*2rVD8_+z`(#0;1lASs+-=y@c%zU zhq3Yh_P>8)7#J8BOM?7@862M7NCR<_yxmdJL>4nJa0`PlBg3pY5)2Fs z>?NMQuI!IES%vr+omSt}Wnf^?^K@|x;kcgsAnL$@1yY9(EMQ%-+>N17g8A^5mFyDB qR?8*KU|X`hjrnN9r*HBS3?EH+bSuohtY%D#ZW* literal 0 HcmV?d00001 diff --git a/resources/g2/font/latin/e-caron-bold.png b/resources/g2/font/latin/e-caron-bold.png new file mode 100644 index 0000000000000000000000000000000000000000..0e1a8126b8cdbed38968596bb93704877dec51e6 GIT binary patch literal 179 zcmeAS@N?(olHy`uVBq!ia0y~yU|?rpVBlh6W?*1oU9@H%0|Nt3fKP~Ps&0A*!~g#b z9mdB0+yDNJVPIfjED7=pW^j0RBMrn!@^*J&=wOxgU|?Y2EbxddW?bP0l+XkKqYf-* literal 0 HcmV?d00001 diff --git a/resources/g2/font/latin/e-caron-tiny.png b/resources/g2/font/latin/e-caron-tiny.png new file mode 100644 index 0000000000000000000000000000000000000000..d7ed34cb11550745450f140230daa9f631d15606 GIT binary patch literal 172 zcmeAS@N?(olHy`uVBq!ia0y~yU|?lnVBlb4W?*3OnSXZ$0|Nt3fKP~Ps&0A*!~g#b z9mdB0+yDNJVPIfjED7=pW^j0RBMrn!@^*J&=wOxgU|?Y2EbxddW? codepointOffsetMap = { { UnicodeChar::c_acute, CSChar::c_acute - CS_SPRITE_FONT_OFFSET }, { UnicodeChar::c_caron_uc, SPR_G2_C_CARON_UPPER - SPR_CHAR_START }, { UnicodeChar::c_caron, SPR_G2_C_CARON_LOWER - SPR_CHAR_START }, + { UnicodeChar::d_caron_uc, SPR_G2_D_CARON_UPPER - SPR_CHAR_START }, + { UnicodeChar::d_caron, SPR_G2_D_CARON_LOWER - SPR_CHAR_START }, { UnicodeChar::e_ogonek_uc, CSChar::e_ogonek_uc - CS_SPRITE_FONT_OFFSET }, { UnicodeChar::e_ogonek, CSChar::e_ogonek - CS_SPRITE_FONT_OFFSET }, + { UnicodeChar::e_caron_uc, SPR_G2_E_CARON_UPPER - SPR_CHAR_START }, + { UnicodeChar::e_caron, SPR_G2_E_CARON_LOWER - SPR_CHAR_START }, { UnicodeChar::g_breve_uc, SPR_G2_G_BREVE_UPPER - SPR_CHAR_START }, { UnicodeChar::g_breve, SPR_G2_G_BREVE_LOWER - SPR_CHAR_START }, { UnicodeChar::i_with_dot_uc, SPR_G2_I_WITH_DOT_UPPER - SPR_CHAR_START }, diff --git a/src/openrct2/localisation/FormatCodes.h b/src/openrct2/localisation/FormatCodes.h index 5ab1b7200d..e844b3eed8 100644 --- a/src/openrct2/localisation/FormatCodes.h +++ b/src/openrct2/localisation/FormatCodes.h @@ -158,8 +158,12 @@ namespace UnicodeChar constexpr char32_t c_acute = 0x107; constexpr char32_t c_caron_uc = 0x10C; constexpr char32_t c_caron = 0x10D; + constexpr char32_t d_caron_uc = 0x10E; + constexpr char32_t d_caron = 0x10F; constexpr char32_t e_ogonek_uc = 0x118; constexpr char32_t e_ogonek = 0x119; + constexpr char32_t e_caron_uc = 0x11A; + constexpr char32_t e_caron = 0x11B; constexpr char32_t g_breve_uc = 0x11E; constexpr char32_t g_breve = 0x11F; constexpr char32_t i_with_dot_uc = 0x130; @@ -168,18 +172,30 @@ namespace UnicodeChar constexpr char32_t l_stroke = 0x142; constexpr char32_t n_acute_uc = 0x143; constexpr char32_t n_acute = 0x144; + constexpr char32_t n_caron_uc = 0x147; + constexpr char32_t n_caron = 0x148; constexpr char32_t o_double_acute_uc = 0x150; constexpr char32_t o_double_acute = 0x151; + constexpr char32_t r_caron_uc = 0x158; + constexpr char32_t r_caron = 0x159; constexpr char32_t s_acute_uc = 0x15A; constexpr char32_t s_acute = 0x15B; constexpr char32_t s_cedilla_uc = 0x15E; constexpr char32_t s_cedilla = 0x15F; + constexpr char32_t s_caron_uc = 0x160; + constexpr char32_t s_caron = 0x161; + constexpr char32_t t_caron_uc = 0x164; + constexpr char32_t t_caron = 0x165; + constexpr char32_t u_ring_uc = 0x16E; + constexpr char32_t u_ring = 0x16F; constexpr char32_t u_double_acute_uc = 0x170; constexpr char32_t u_double_acute = 0x171; constexpr char32_t z_acute_uc = 0x179; constexpr char32_t z_acute = 0x17A; constexpr char32_t z_dot_uc = 0x17B; constexpr char32_t z_dot = 0x17C; + constexpr char32_t z_caron_uc = 0x17D; + constexpr char32_t z_caron = 0x17E; constexpr char32_t f_with_hook_uc = 0x191; constexpr char32_t s_comma_uc = 0x218; constexpr char32_t s_comma = 0x219; diff --git a/src/openrct2/sprites.h b/src/openrct2/sprites.h index f6cbd50356..67daaf715e 100644 --- a/src/openrct2/sprites.h +++ b/src/openrct2/sprites.h @@ -924,7 +924,12 @@ enum SPR_G2_U_DOUBLE_ACUTE_UPPER = SPR_G2_CHAR_BEGIN + 68, SPR_G2_U_DOUBLE_ACUTE_LOWER = SPR_G2_CHAR_BEGIN + 69, - SPR_G2_CHAR_END = SPR_G2_U_DOUBLE_ACUTE_LOWER, + SPR_G2_D_CARON_UPPER = SPR_G2_CHAR_BEGIN + 70, + SPR_G2_D_CARON_LOWER = SPR_G2_CHAR_BEGIN + 71, + SPR_G2_E_CARON_UPPER = SPR_G2_CHAR_BEGIN + 72, + SPR_G2_E_CARON_LOWER = SPR_G2_CHAR_BEGIN + 73, + + SPR_G2_CHAR_END = SPR_G2_E_CARON_LOWER, SPR_G2_GLYPH_COUNT = (SPR_G2_CHAR_END - SPR_G2_CHAR_BEGIN) + 1, // 0x60000, chosen because it's a round hex number