mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-28 11:49:44 +00:00
LibCore+LibGfx: Move font_directories from LibCore to LibGfx
the goal is to rely on fontconfig for font directory resolution. it doesn't seem like it would be appropritate to call to fontconfig funcs from within the LibCore. i'm not 100% confident that FontDatabase is the correct place.. seems okay?
This commit is contained in:
parent
6e00a38099
commit
4b3691ff39
Notes:
github-actions[bot]
2025-05-26 18:15:38 +00:00
Author: https://github.com/blukai
Commit: 4b3691ff39
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4830
Reviewed-by: https://github.com/ADKaster ✅
5 changed files with 53 additions and 51 deletions
|
@ -36,7 +36,7 @@ FontPlugin::FontPlugin(bool is_layout_test_mode, Gfx::SystemFontProvider* font_p
|
|||
if (is<Gfx::PathFontProvider>(*font_provider)) {
|
||||
auto& path_font_provider = static_cast<Gfx::PathFontProvider&>(*font_provider);
|
||||
// Load anything we can find in the system's font directories
|
||||
for (auto const& path : Core::StandardPaths::font_directories().release_value_but_fixme_should_propagate_errors())
|
||||
for (auto const& path : Gfx::FontDatabase::font_directories().release_value_but_fixme_should_propagate_errors())
|
||||
path_font_provider.load_all_fonts_from_uri(MUST(String::formatted("file://{}", path)));
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue