Skip to content
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

Failing to rasterize non-latin character correctly #89

Open
andresperezl opened this issue Jan 14, 2022 · 1 comment
Open

Failing to rasterize non-latin character correctly #89

andresperezl opened this issue Jan 14, 2022 · 1 comment

Comments

@andresperezl
Copy link

Go 1.17.6
Windows 11 amd64
github.com/golang/freetype v0.0.0-20170609003504-e2365dfdc4a0

I'm trying to use the library to draw some text in transparent background, but it doesn't matter what font I use, it fails to correctly rasterize non-latin characters:

out

Here is a screenshot of Notepad using the same font:

image

@nigeltao
Copy link
Contributor

Notepad using the same font

Be aware that Notepad would be using font fallbacks. If "the same font" didn't actually have Chinese, Japanese or Korean characters, Notepad (or something in the Win32 UI stack) would find another font that did.

Freetype (whether the C or Go flavors) does not do font fallback. You'd need (the Go equivalent) of font-config (on Linux) or something similar (on Windows).

Can you attach the font?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants