mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 15:57:45 +00:00
LibWeb: Implement most of the CSS table fixup algorithm
This patch implements the "remove irrelevant boxes" and "generate missing child wrappers" parts of table fixup. "Generate missing parents" is left as a task for our future selves.
This commit is contained in:
parent
0fd577084f
commit
56c2cc4162
5 changed files with 175 additions and 1 deletions
|
@ -44,6 +44,14 @@ private:
|
|||
void push_parent(Layout::NodeWithStyle& node) { m_parent_stack.append(&node); }
|
||||
void pop_parent() { m_parent_stack.take_last(); }
|
||||
|
||||
template<CSS::Display, typename Callback>
|
||||
void for_each_in_tree_with_display(NodeWithStyle& root, Callback);
|
||||
|
||||
void fixup_tables(NodeWithStyle& root);
|
||||
void remove_irrelevant_boxes(NodeWithStyle& root);
|
||||
void generate_missing_child_wrappers(NodeWithStyle& root);
|
||||
void generate_missing_parents(NodeWithStyle& root);
|
||||
|
||||
RefPtr<Layout::Node> m_layout_root;
|
||||
Vector<Layout::NodeWithStyle*> m_parent_stack;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue