-
Notifications
You must be signed in to change notification settings - Fork 831
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Locale-aware Typography #2608
Comments
Thanks for the comprehensive description of the issue. Just a few remarks. That this style is referred to as "Mapnik" is a left-over from previous days where there was a "Mapnik" and "Osmarender" rendering. Today it is often less confusing to refer to this style as openstreetmap-carto or osm-carto. We tend to avoid country-specific renderings as it is complex and leads to all sorts of problems and wishes. Would there be another way to determine from the OSM data what font to use apart from evaluating boundaries? Would Mapnik (the software) understand this |
Perhaps this can be done by equivalence checks between
Not sure, to be honest. It seems to use some harfbuzz which does do the OpenType part right.
Pretty odd I would say. I do recall seeing a lot of people being unhappy with what they got after installing the Japanese version of Source Han Sans... 门's difference is probably one of the most obvious in all differences seen between jp/cn variants of a Chinese character. Unfortunately both cultures have a lot of gates to deal with. |
Duplicate of #2208 |
Quite a few Unified CJK Ideographs ("Chinese Characters") are written in different ways in different countries/languages. Such difference is why Adobe and Google has released a bunch of local variants for their Source Han Sans/Noto Sans CJK fonts. In Mapnik for example, at https://www.openstreetmap.org/way/25097203, the "门" (door, gate) character (the last char on its own line) happens to be presented in the Japanese form with a vertical stroke over its rectangular body:
Since these locations are found in China, a Chinese form is expected for these characters. Such form is shown below, from a screenshot of, well, this issue:

(There are quite a few other "门"s to the north.)
I understand that OSM's current rendering, generally only taking the
name
part without a language label attached, cannot reliably infer the language used for the string and therefore thelocl
value to use for font rendering (as well as just the language value to feed into stuff like fontconfig). But with a crude heuristic based on national/regional borders, OSM should be able to get most of the cases right.A Latin-script (Romanian) example of such a
locl
feature is available at https://en.wikipedia.org/wiki/Pango#Support_for_OpenType_features. Also try pasting "关门吃草逛街" into the four previews at https://typekit.com/lists/source-han-sans.(moved from mapnik/mapnik#3655)
The text was updated successfully, but these errors were encountered: