[mathml] Refine when legacy/NG layout is forced #25522
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is a refinement of [1] [2] [3] [4]:
non-math display.
([1] was only doing that for the inherited child context).
layout, but only on non-math display values. Note that this check is
not necessary in LayoutObjectFactory::CreateMath which is only called
for math display values.
why [3] had a special case and that does not match the spec).
Ideally, 3. can be removed when we completely switch to NG layout for
all displays. New tests are added to verify related crashes found by
clusterfuzz and check overriding of the layout MathML elements with
various display values.
[1] https://chromium-review.googlesource.com/c/chromium/src/+/2398702
[2] https://chromium-review.googlesource.com/c/chromium/src/+/2397949
[3] https://chromium-review.googlesource.com/c/chromium/src/+/1985766
[4] https://chromium-review.googlesource.com/c/chromium/src/+/1917207
Bug: 6606, 1127628, 1127407, 1127222
Change-Id: I62b0ef4de623f4eb93184a1cecce598905160dad
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2409957
Commit-Queue: Frédéric Wang <fwang@igalia.com>
Reviewed-by: Morten Stenshorne <mstensho@chromium.org>
Reviewed-by: Ian Kilpatrick <ikilpatrick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#806771}