summaryrefslogtreecommitdiff
path: root/Userland
diff options
context:
space:
mode:
authorAndreas Kling <kling@serenityos.org>2022-09-14 21:24:31 +0200
committerAndreas Kling <kling@serenityos.org>2022-09-14 21:24:31 +0200
commitf64c1759600ba4a4b591607070926219eec2fe48 (patch)
treedc5cf7e225ad46fe6dc9d8a74426fe30d67ba3b2 /Userland
parentdf49a6ae9b7b45473c8019b35ab10ffa5e064f2b (diff)
downloadserenity-f64c1759600ba4a4b591607070926219eec2fe48.zip
LibWeb: Invalidate layout whenever a CSS font is loaded
It's not enough to invalidate only the style, we have to do a full layout invalidation since new fonts might mean new metrics, etc.
Diffstat (limited to 'Userland')
-rw-r--r--Userland/Libraries/LibWeb/CSS/StyleComputer.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/Userland/Libraries/LibWeb/CSS/StyleComputer.cpp b/Userland/Libraries/LibWeb/CSS/StyleComputer.cpp
index 0f4c201f8c..4e8a121c46 100644
--- a/Userland/Libraries/LibWeb/CSS/StyleComputer.cpp
+++ b/Userland/Libraries/LibWeb/CSS/StyleComputer.cpp
@@ -1344,7 +1344,7 @@ Gfx::IntRect StyleComputer::viewport_rect() const
void StyleComputer::did_load_font([[maybe_unused]] FlyString const& family_name)
{
- document().invalidate_style();
+ document().invalidate_layout();
}
void StyleComputer::load_fonts_from_sheet(CSSStyleSheet const& sheet)