From 400c298abd3b6cb081c9cfb5674c3aeb69f62346 Mon Sep 17 00:00:00 2001 From: Paul Norman Date: Fri, 15 Jul 2022 20:38:25 -0700 Subject: [PATCH] Sort Noto Sans CJK with Arabic Like Arabic, we don't want this font to redefine the rendering of common symbols. --- style/fonts.mss | 49 +++++++++++++++++++++++-------------------------- 1 file changed, 23 insertions(+), 26 deletions(-) diff --git a/style/fonts.mss b/style/fonts.mss index 2edf2aaf14..d852a2e04f 100644 --- a/style/fonts.mss +++ b/style/fonts.mss @@ -14,37 +14,34 @@ used in “name” tags in OSM. Most of the list is in alphabetical order, but there are some exceptions. - Noto Sans is before all other fonts - - The CJK fonts are manually ordered. The used CJK font covers all CJK - languages, but defaults to the japanese glyph style if various glyph - styles are available. We have to default to one of JP, KR, SC, TC because - this carto style has no knowledge about what language the “names” tag - contains. As in Korea Han characters are not so widely used, it seems - better to default to either Chinese or Japanese. As Chinese exists in the - two variants SC/TC, it won’t be a uniform rendering anyway. So we default - to Japanese. However, this choice stays somewhat arbitrary and subjective. - See also https://github.com/gravitystorm/openstreetmap-carto/issues/2208 - -2. Noto provides various variants of Arabic: Noto Kufi Arabic, Noto Naskh -Arabic, Noto Nastaliq Urdu and Noto Sans Arabic. Kufi and Urdu styles are not -widespread in use. Noto Sans Arabic (a Naskh-style low-contrast “Sans” font) and -Noto Naskh Arabic are the fonts with the greatest coverage and provide an UI -variant. This style uses Noto Sans Arabic UI because it’s consistent with the -other Sans fonts and legible. The Arabic fonts are placed behind Sans fonts -because they might re-define some commonly used signs like parenthesis or -quotation marks, and the arabic design should not overwrite the standard design. -The list still includes Noto Naskh Arabic UI for compatibility on systems -without Noto Sans Arabic UI. - -3. Noto Serif is used for scripts that are not supported by Noto Sans. Currently + + - Noto Arabic and Noto CJK JP are placed behind sans fonts because commonly + used signs like parenthesis or quotation marks, and their design should + not overwrite the standard design. + +3. The used CJK font covers all CJK languages, but defaults to the Japanese +glyph style if various glyph styles are available. We have to default to one +of JP, KR, SC, TC because this style has no knowledge about what language the +“names” tag contains. As in Korea Han characters are not so widely used, it is +better to default to either Chinese or Japanese. As Chinese exists in the two +variants SC/TC, it won’t be a uniform rendering anyway. So we default to +Japanese. However, this choice stays somewhat arbitrary and subjective. + +4. Similar to CJK Han Unification, there are multiple scripts for Arabic +scripts, and the style has no way to know what language the text is in. This +style uses Noto Sans Arabic UI because it’s consistent with the other Sans +fonts and legible. + +5. Noto Serif is used for scripts that are not supported by Noto Sans. Currently this is only Tibetan: The old Noto Sans Tibetan has been renamed to Noto Serif Tibetan in 2015, since then only Noto Serif Tibetan gets updated. -4. Noto provides two variants of Emoji: Noto Color Emoji and Noto Emoji. The +6. Noto provides two variants of Emoji: Noto Color Emoji and Noto Emoji. The colour variant is a SVG flavoured OpenType font that contains coloured emojis. This is not useful in cartography, so we use the “normal” monochromatic Noto Emoji. -5. Fallback fonts. Hanazono covers almost all CJK characters, even in Unicode +7. Fallback fonts. Hanazono covers almost all CJK characters, even in Unicode Plane 2. */ @@ -55,7 +52,6 @@ font-directory: url('fonts'); A regular style. */ @book-fonts: "Noto Sans Regular", - "Noto Sans CJK JP Regular", "Noto Sans Adlam Regular", "Noto Sans Adlam Unjoined Regular", "Noto Sans Armenian Regular", @@ -116,6 +112,7 @@ A regular style. "Noto Sans Vai Regular", "Noto Sans Yi Regular", + "Noto Sans CJK JP Regular", "Noto Sans Arabic UI Regular", "Noto Naskh Arabic UI Regular", "Noto Serif Tibetan Regular", @@ -129,7 +126,6 @@ A bold style is available for almost all scripts. Bold text is heavier than regular text and can be used for emphasis. Fallback is a regular style. */ @bold-fonts: "Noto Sans Bold", - "Noto Sans CJK JP Bold", "Noto Sans Adlam Bold", "Noto Sans Adlam Unjoined Bold", "Noto Sans Armenian Bold", @@ -165,6 +161,7 @@ regular text and can be used for emphasis. Fallback is a regular style. "Noto Sans Thaana Bold", "Noto Sans Thai UI Bold", + "Noto Sans CJK JP Bold", "Noto Sans Arabic UI Bold", "Noto Naskh Arabic UI Bold", "Noto Serif Tibetan Bold",