Replace our existing two fonts with a stack of new fonts to increase
and improve language coverage and to add many new symbols and icons.
This proposed change is to replace the two font files currently found in the datafiles/fonts folder with the contents of the following zip archive:
Because of this improved coverage, this patch also prints out a message to the console if a glyph is not found. Note that this will only happen the first time that character is asked for, not every time it is encountered.
Current Fonts:
The current fonts are "droidsans.ttf" (5.09 MB, containing 54017 glyphs), and "bmonofont-i18n.ttf" (5.31 MB, containing 51649 glyphs). These currently contain a differing number of languages (mono font not containing Devanagari and Tamil for example). They are also contain only a subset of the Arabic presentation symbols (62 & 72 out of 611), which will be needed for complex shaping (different glyphs depending on whether the letter is at the beginning, middle, or end of word). They also contain a minimum number of CJK ideographs (528/996 for Phonetics & Symbols, 35/64 Punctuation, 2/6582 of Extension A).
In summary the two fonts cover under 55,000 glyphs with two files totaling 10.4 MB.
Proposed Fonts
The proposed 25 fonts total 14.7 MB, so a 41% file size increase. But with substantially increase language and glyph coverage. In fact enough to cover all of the top 44 languages by number of speakers. This represents about 1.5 billion more people who can view their language in Blender. They also feature thousands of new symbols and icons.
| DejaVuSans.woff2 | 257,564 |
| DejaVuSansMono.woff2 | 145,192 |
| lastresort.woff2 | 118,564 |
| Noto Sans CJK Regular.woff2 | 11,672,912 |
| NotoEmoji-VariableFont_wght.woff2 | 1,026,984 |
| NotoSansArabic-VariableFont_wdth,wght.woff2 | 253,496 |
| NotoSansArmenian-VariableFont_wdth,wght.woff2 | 47,492 |
| NotoSansBengali-VariableFont_wdth,wght.woff2 | 226,740 |
| NotoSansDevanagari-Regular.woff2 | 69,872 |
| NotoSansEthiopic-Regular.woff2 | 92,608 |
| NotoSansGeorgian-VariableFont_wdth,wght.woff2 | 101,524 |
| NotoSansGujarati-Regular.woff2 | 58,668 |
| NotoSansGurmukhi-VariableFont_wdth,wght.woff2 | 66,568 |
| NotoSansHebrew-VariableFont_wdth,wght.woff2 | 17,544 |
| NotoSansJavanese-Regular.woff2 | 34,144 |
| NotoSansKannada-VariableFont_wdth,wght.woff2 | 156,260 |
| NotoSansMalayalam-VariableFont_wdth,wght.woff2 | 159,848 |
| NotoSansMath-Regular.woff2 | 226,460 |
| NotoSansMyanmar-Regular.woff2 | 64,692 |
| NotoSansSymbols-VariableFont_wght.woff2 | 152,244 |
| NotoSansSymbols2-Regular.woff2 | 201,324 |
| NotoSansTamil-VariableFont_wdth,wght.woff2 | 98,380 |
| NotoSansTelugu-VariableFont_wdth,wght.woff2 | 209,708 |
| NotoSansThai-VariableFont_wdth,wght.woff2 | 46,852 |
In the above list you will notice that the new languages added represent a very small part of the total. The majority of the space is in the CJK for increased coverage of Chinese, Japanese, and Korean. This one file contains 65,535 glyphs.
The two base fonts, "DejaVuSans.woff2" and "DejaVuSansMono.woff2" are the current replacements for our base fonts. Therefore you should see no difference from current fonts when viewing Latin characters.
These fonts all match well, being mostly from the "Noto" font family, which are designed to coexist coherently.
The "lastresort" font is a special type of font that will always return a symbol of some kind for characters that are otherwise not found.
Almost of these fonts are "variable" type in that they each contain a range of design variations along multiple axes. Basically an infinite number of font variations in one file. Although we won't notice this immediately, we can add specific support for this in D12977: BLF: Add Support for Variable Fonts and hopefully take advantage of this when we use these fonts for 3D text.
There is almost perfect coverage here for math and technical symbols. I am just a bit anal about covering these things well.
The "emoji" font file could come in handy for all the related ideographs. Addon authors could use them for example.
