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

Very frequent log messages about font fallback #135

Closed
kaimast opened this issue Jun 4, 2023 · 1 comment · Fixed by #145
Closed

Very frequent log messages about font fallback #135

kaimast opened this issue Jun 4, 2023 · 1 comment · Fixed by #145

Comments

@kaimast
Copy link

kaimast commented Jun 4, 2023

When running the examples I get very frequent (dozens per second) log messages like that:

[2023-06-04T20:40:18Z DEBUG cosmic_text::font::fallback] failed to find family 'Noto Sans'
[2023-06-04T20:40:18Z DEBUG cosmic_text::font::fallback] failed to find family 'DejaVu Sans'
[2023-06-04T20:40:18Z DEBUG cosmic_text::font::fallback] failed to find family 'FreeSans'
[2023-06-04T20:40:18Z DEBUG cosmic_text::font::fallback] failed to find family 'Noto Sans Mono'
[2023-06-04T20:40:18Z DEBUG cosmic_text::font::fallback] failed to find family 'DejaVu Sans Mono'
[2023-06-04T20:40:18Z DEBUG cosmic_text::font::fallback] failed to find family 'FreeMono'
[2023-06-04T20:40:18Z DEBUG cosmic_text::font::fallback] failed to find family 'Noto Sans Symbols'
[2023-06-04T20:40:18Z DEBUG cosmic_text::font::fallback] failed to find family 'Noto Sans Symbols2'
[2023-06-04T20:40:18Z DEBUG cosmic_text::font::fallback] Failed to find preset fallback for [] locale 'en-US', used 'Verdana': 'Word'

It seems like the library is constantly trying to resolve fallback fonts instead of doing it once and caching the outcome.

The resulting performance is extremely bad as well. For example, I need to run the editor in release mode for it to be somewhat responsive.

@kaimast
Copy link
Author

kaimast commented Jun 26, 2023

I don't think this is fixed for me... Cosmic still creates a bunch of log messages ever time I type a letter.

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

Successfully merging a pull request may close this issue.

1 participant