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

LibWeb: Move line-height from NodeWithStyle to ComputedValues

There's no need for this to live in the NodeWithStyle anymore. By moving
it to ComputedValues we get all the right inheritance behavior for free.
This commit is contained in:
Andreas Kling 2024-01-12 15:34:13 +01:00
parent e7de5cb4d2
commit c82d517447
8 changed files with 20 additions and 24 deletions

View file

@ -1134,7 +1134,7 @@ void BlockFormattingContext::layout_list_item_marker(ListItemBox const& list_ite
list_item_state.set_content_width(list_item_state.content_width() - final_marker_width);
}
auto offset_y = max(CSSPixels(0), (marker.line_height() - marker_state.content_height()) / 2);
auto offset_y = max(CSSPixels(0), (marker.computed_values().line_height() - marker_state.content_height()) / 2);
auto space_and_containing_margin = intrusion_by_floats_into_box(list_item_box, offset_y);
marker_state.set_content_offset({ space_and_containing_margin.left - final_marker_width, offset_y });