-
Notifications
You must be signed in to change notification settings - Fork 109
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
Some characteres are not rendered #117
Comments
If you want automatic glyph substitution you want something a bit higher level than freetype (and SharpFont). Perhaps cairo (cairoSharp)? Alternatively you might want to use a font with wider coverage, such as one of the google pan cjk ones? |
@HinTak is correct, the font itself likely doesn't have those glyphs in it. LibreOffice itself uses Cairo for the higher level text rendering logic, like substituting missing glyphs for those in a default (or similar) font. Cairo, in turn, uses freetype to render glyphs. |
@TomQv In the case of OpenDocument, the OS's display system (i.e. windows or gtk) did the substitution for you. The same thing happens if you type those texts in a text box on the browser. It is perhaps happening even higher than Cairo, at the pango (i.e. layout of sentences and words) level. Pango/Cairo uses fontconfig to find other fonts for relevant substitutions, before invoking freetype. The right-to-left layout in LibreOffice is done by pango. |
Thanks, so I must find a more complete font, since I don't want to go for cairo or similar, SharpFont is just right for us. |
I meant the Google Noto fonts. They supports CJK, but not only CJK. Hanazono is also extremely large. Wikipedia has a list... |
Google Noto has this font, its in "Berber (Tifinagh script)", and only there. and no others. |
I'm trying to render this string using "Arial Unicode.ttf":
var test = _fontFace.GetCharIndex(oneletter);
_fontFace.LoadChar(oneletter, LoadFlags.Render, LoadTarget.Normal);
var ftbitmap = _fontFace.Glyph.Bitmap;
Morocco / Maroc ⴰⵎⵔⵔⵓⴽ المغرب
The middle-part ⴰⵎⵔⵔⵓⴽ is not rendered, the rest is fine. For the letters which are not rendered, the test=GetCharIndex is also 0. I'm not very familiar with these font/unicode-stuff, maybe this letter is just not in Arial? But when I paste the string for example in an editor and use Arial, its rendered fine.
Is there a trick to get these letters rendered too?
Thanks
Tom
The text was updated successfully, but these errors were encountered: