diff options
author | Andreas Kling <kling@serenityos.org> | 2020-06-24 21:44:11 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2020-06-24 21:44:11 +0200 |
commit | 8960c6f8fe01f16869413139e2e405f74a50d08d (patch) | |
tree | f7dae64760386297219c187e4d0d42576ceb1069 /Libraries | |
parent | 440b4ece22dd0c165b4d8055ea2f066e8ba1c8c5 (diff) | |
download | serenity-8960c6f8fe01f16869413139e2e405f74a50d08d.zip |
LibWeb: Use the cached white-space from LayoutStyle in text_for_style()
Diffstat (limited to 'Libraries')
-rw-r--r-- | Libraries/LibWeb/Layout/LayoutText.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Libraries/LibWeb/Layout/LayoutText.cpp b/Libraries/LibWeb/Layout/LayoutText.cpp index bb26f24d78..027aaa9944 100644 --- a/Libraries/LibWeb/Layout/LayoutText.cpp +++ b/Libraries/LibWeb/Layout/LayoutText.cpp @@ -59,7 +59,7 @@ const String& LayoutText::text_for_style(const StyleProperties& style) const { static String one_space = " "; if (is_all_whitespace(node().data())) { - if (style.string_or_fallback(CSS::PropertyID::WhiteSpace, "normal") == "normal") + if (style.white_space().value_or(CSS::WhiteSpace::Normal) == CSS::WhiteSpace::Normal) return one_space; } return node().data(); |