Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 500c94501f7f041167e2671087e51df2f2672880
      
https://github.com/WebKit/WebKit/commit/500c94501f7f041167e2671087e51df2f2672880
  Author: Frédéric Wang <[email protected]>
  Date:   2024-07-04 (Thu, 04 Jul 2024)

  Changed paths:
    M 
LayoutTests/imported/w3c/web-platform-tests/mathml/presentation-markup/fractions/frac-1-expected.txt
    M 
LayoutTests/imported/w3c/web-platform-tests/mathml/presentation-markup/mrow/no-spacing-expected.txt
    M 
LayoutTests/imported/w3c/web-platform-tests/mathml/relations/css-styling/not-participating-to-parent-layout-expected.txt
    M 
LayoutTests/imported/w3c/web-platform-tests/mathml/relations/css-styling/padding-border-margin/border-002-expected.txt
    M 
LayoutTests/imported/w3c/web-platform-tests/mathml/relations/css-styling/padding-border-margin/margin-002-expected.txt
    M 
LayoutTests/imported/w3c/web-platform-tests/mathml/relations/css-styling/padding-border-margin/margin-003-expected.txt
    M 
LayoutTests/imported/w3c/web-platform-tests/mathml/relations/css-styling/padding-border-margin/padding-002-expected.txt
    M 
LayoutTests/platform/glib/imported/w3c/web-platform-tests/mathml/relations/css-styling/padding-border-margin/border-002-expected.txt
    M 
LayoutTests/platform/glib/imported/w3c/web-platform-tests/mathml/relations/css-styling/padding-border-margin/margin-003-expected.txt
    M LayoutTests/platform/glib/mathml/presentation/roots-expected.txt
    M 
LayoutTests/platform/gtk/imported/w3c/web-platform-tests/mathml/relations/css-styling/not-participating-to-parent-layout-expected.txt
    M 
LayoutTests/platform/gtk/imported/w3c/web-platform-tests/mathml/relations/css-styling/padding-border-margin/padding-002-expected.txt
    M 
LayoutTests/platform/ios/imported/w3c/web-platform-tests/mathml/relations/css-styling/padding-border-margin/padding-002-expected.txt
    M LayoutTests/platform/ios/mathml/presentation/roots-expected.txt
    M 
LayoutTests/platform/mac/imported/w3c/web-platform-tests/mathml/relations/css-styling/padding-border-margin/padding-002-expected.txt
    M LayoutTests/platform/mac/mathml/presentation/roots-expected.txt
    M Source/WebCore/rendering/mathml/RenderMathMLFraction.cpp
    M Source/WebCore/rendering/mathml/RenderMathMLSpace.cpp

  Log Message:
  -----------
  Support border/margin/padding on mfrac and mspace elements
https://bugs.webkit.org/show_bug.cgi?id=276218

Reviewed by Rob Buis.

This implements support for border/margin/padding on the mfrac and
mspace elements, following the rules from the MathML Core specification:

- When handling boxes of children during math layout, we consider *margin*
  boxes. Following other renderers, `recomputeLogicalWidth()` is called
  during the layout of children to set the inline margins while
  `computeAndSetBlockDirectionMargins()` is called during the parent
  layout to set the block margins.

- Current math layout is modified so that padding/border are added in
  order to obtain the border box. In the case of mfrac, the fraction
  bar continues to be aligned with the math axis and to cover the
  numerator/denominator's margin boxes. In the case of mspace, the
  baseline alignment is preserved.

- In bug 262789, a padding start/end of 1px for mfrac was added to the
  UA stylesheet. With the present patch, we take this into account for
  layout, allowing to address the use case mentioned in the spec
  "To avoid visual confusion between the fraction bar and another
   adjacent items (e.g. minus sign or another fraction's bar) a
   default 1-pixel space is added around the element.".

Canonical link: https://commits.webkit.org/280665@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to