forked from aseprite/laf
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add SpriteTextBlob to improve the rendering of SpriteSheetFont with n…
…on-existent chars To render text with a SpriteSheetFont we now create a SpriteTextBlob. This blob can render non-existent code points using a default fallback native font (SkiaFont) and create a chain of runs for each TextBlob that use a different font. In this way we don't change the whole appearance of the rendered text with an antialiased font when a missing code point appears. We just use the fallback font to render that specific code point/char (or sequence of chars in one run). This problem was reported several times and we can find examples here: aseprite/aseprite#2890 (comment) As a side note, all code/static functions that use a text shaper (HarfBuzz, skshaper module, etc.) is separated in its own file (i.e. translation unit) to make binary executable files smaller when the shaper is not needed (e.g. in English-only apps).
- Loading branch information
Showing
17 changed files
with
831 additions
and
471 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.