1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-19 20:35:06 +00:00

LibHTML: Implement basic block height computation

..and add vertical box properties to the layout tree dumps.
This commit is contained in:
Andreas Kling 2019-08-18 08:37:53 +02:00
parent 70eca3b500
commit fc43cf929d
4 changed files with 72 additions and 18 deletions

View file

@ -61,6 +61,14 @@ public:
Display display() const;
Length length_or_fallback(const StringView& property_name, const Length& fallback)
{
auto value = property(property_name);
if (!value.has_value())
return fallback;
return value.value()->to_length();
}
protected:
explicit StyledNode(const Node*);