Repository navigation
[WIP] Use fontdb to search fonts, with basic fontconfig support - #2472
Merged
Merged
Conversation
Member
|
As expected it does a little more and duplicate work, which degraded performance a little on my system (~8%), but that's not the end of the world. Fundamentally, scanning a bunch of directories for fonts and collecting their metadata is just a slow process. Would be nice to either use system APIs (hard to get the right metadata) or somehow cache this process in the future. But this is already a good improvement on Linux. |
laurmaedje
force-pushed
the
cli/fontdb
branch
from
October 25, 2023 16:27
6575646 to
c9d0338
Compare
Member
|
Thank you! |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
According to discuss in #100, this PR use fontdb to repalce the home-made font searcher in cli.
This is not expected to bring about big changes. Except in Linux, fontdb will try to find config file of fontconfig, parse it(using fontconfig-parser) and load dirs configured in those file.
Notice that fontconfig-parser is not a binding to the fontconfig C lib, but just a parser. So the specific behavior may be inconsistent with using the fontconfig program, which is expected.