mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 13:17:35 +00:00
LibWeb: Move layout box rect helpers into FormattingContext
These are only used during layout, and always within formatting context code, so we might as well put them in FormattingContext and avoid having to pass the LayoutState around all the time.
This commit is contained in:
parent
4f08fcde29
commit
42470d837e
10 changed files with 155 additions and 152 deletions
|
@ -211,7 +211,7 @@ void LineBuilder::update_last_line()
|
|||
fragment_baseline = CSSPixels(font_metrics.ascent) + half_leading;
|
||||
} else {
|
||||
auto const& box = verify_cast<Layout::Box>(fragment.layout_node());
|
||||
fragment_baseline = box_baseline(m_layout_state, box);
|
||||
fragment_baseline = m_context.box_baseline(box);
|
||||
}
|
||||
|
||||
// Remember the baseline used for this fragment. This will be used when painting the fragment.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue