1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-28 16:07:45 +00:00

LibWeb: Show formatting context roots in layout tree dumps

This patch does three things:

- Factors out the code that determines whether a box will create a new
  formatting context for its children (and which type of context)

- Uses that code to mark all formatting context roots in layout tree
  dumps. This makes it much easier to follow along with layout since
  you can now see exactly where control is transferred to a new
  formatting context.

- Rebaselines all existing layout tests, since the output format has
  changed slightly.
This commit is contained in:
Andreas Kling 2023-05-03 10:32:23 +02:00
parent 42e118e6a9
commit 968db96101
117 changed files with 905 additions and 851 deletions

View file

@ -1,5 +1,5 @@
Viewport <#document> at (0,0) content-size 800x600 children: not-inline
BlockContainer <html> at (0,0) content-size 800x36 children: not-inline
BlockContainer <html> at (0,0) content-size 800x36 [BFC] children: not-inline
BlockContainer <body> at (8,8) content-size 784x20 children: inline
line 0 width: 352.34375, height: 20, bottom: 20, baseline: 13.53125
frag 0 from TextNode start: 0, length: 14, rect: [8,8 112.421875x17.46875]
@ -8,7 +8,7 @@ Viewport <#document> at (0,0) content-size 800x600 children: not-inline
frag 2 from TextNode start: 0, length: 16, rect: [231,8 129.546875x17.46875]
"more inline text"
TextNode <#text>
BlockContainer <span.displaced_text> at (150,48) content-size 110.375x20 positioned inline-block children: inline
BlockContainer <span.displaced_text> at (150,48) content-size 110.375x20 positioned inline-block [BFC] children: inline
line 0 width: 110.375, height: 17.46875, bottom: 17.46875, baseline: 13.53125
frag 0 from TextNode start: 0, length: 14, rect: [150,48 110.375x17.46875]
"displaced text"