mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-05-06 03:02:55 +00:00
LibHTML: Implement basic block height computation
..and add vertical box properties to the layout tree dumps.
This commit is contained in:
parent
70eca3b500
commit
fc43cf929d
Notes:
sideshowbarker
2024-07-19 12:37:24 +09:00
Author: https://github.com/awesomekling
Commit: fc43cf929d
4 changed files with 72 additions and 18 deletions
|
@ -65,9 +65,19 @@ void dump_tree(const LayoutNode& layout_node)
|
|||
layout_node.style().border().left.to_px(),
|
||||
layout_node.style().padding().left.to_px(),
|
||||
layout_node.rect().width(),
|
||||
layout_node.style().margin().right.to_px(),
|
||||
layout_node.style().padding().right.to_px(),
|
||||
layout_node.style().border().right.to_px(),
|
||||
layout_node.style().padding().right.to_px());
|
||||
layout_node.style().margin().right.to_px());
|
||||
|
||||
// And the vertical box properties
|
||||
printf(" [%d+%d+%d %d %d+%d+%d]",
|
||||
layout_node.style().margin().top.to_px(),
|
||||
layout_node.style().border().top.to_px(),
|
||||
layout_node.style().padding().top.to_px(),
|
||||
layout_node.rect().height(),
|
||||
layout_node.style().padding().bottom.to_px(),
|
||||
layout_node.style().border().bottom.to_px(),
|
||||
layout_node.style().margin().bottom.to_px());
|
||||
|
||||
if (layout_node.is_text())
|
||||
printf(" \"%s\"", static_cast<const LayoutText&>(layout_node).text().characters());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue