Bug 1672969 [wpt PR 26254] - Revert "[mathml] Implement special drawing of largeop operator in displaystyle", a=testonly

Automatic update from web-platform-tests
Revert "[mathml] Implement special drawing of largeop operator in displaystyle"

This reverts commit 830b5b3af88cbe3fc7e6169c9772fdebe01f6797.

Reason for revert: Causing crashes in several mathml tests on the MSAN bot. First failing build: https://ci.chromium.org/p/chromium/builders/ci/WebKit%20Linux%20MSAN/8001

Original change's description:
> [mathml] Implement special drawing of largeop operator in displaystyle
>
> This implements special drawing of largeop <mo> element in display style
> as described in step 3. of [1]. A new algorithm is introduced for that
> purpose and in particular only used for <mo> elements that are made of
> a single glyph. Existing painting logic for stretchy radical symbol is
> reused and adapted to work with largeop operators.
>
> [1] https://mathml-refresh.github.io/mathml-core/#layout-of-operators
>
> Bug: 6606
> Change-Id: Icca70f4bf464417809970fecc101e5aa7f149621
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2414298
> Commit-Queue: Rob Buis <rbuis@igalia.com>
> Reviewed-by: Koji Ishii <kojii@chromium.org>
> Reviewed-by: Frédéric Wang <fwang@igalia.com>
> Reviewed-by: Ian Kilpatrick <ikilpatrick@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#819855}

TBR=wangxianzhu@chromium.org,kojii@chromium.org,ikilpatrick@google.com,ikilpatrick@chromium.org,fwang@igalia.com,mstensho@chromium.org,rbuis@igalia.com

Change-Id: I97a8a0708d5acd3d43fd67a2deff3fed5967fc5e
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: 6606
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2495061
Reviewed-by: Bret Sepulveda <bsep@chromium.org>
Commit-Queue: Bret Sepulveda <bsep@chromium.org>
Cr-Commit-Position: refs/heads/master@{#820204}

--

wpt-commits: 0c6b6ed8b55e50fbf5669874815bd6ea0eb1c5a9
wpt-pr: 26254
This commit is contained in:
Bret Sepulveda 2020-10-24 10:43:53 +00:00 коммит произвёл moz-wptsync-bot
Родитель 486b65950e
Коммит e07e95f1c0
3 изменённых файлов: 0 добавлений и 115 удалений

Просмотреть файл

@ -1,63 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Test hit testing on large operators</title>
<meta name="assert" content="Verify that hit testing works on large operators.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/mathml/support/feature-detection.js"></script>
<style>
@font-face {
font-family: TestFont;
src: url("/fonts/math/largeop-displayoperatorminheight5000.woff");
}
mo {
font-family: TestFont;
font-size: 16px;
}
</style>
<script>
function getBox(aId) {
return document.getElementById(aId).getBoundingClientRect();
}
setup({ explicit_done: true });
window.addEventListener("load", () => { document.fonts.ready.then(runTests); });
function runTests() {
test(function() {
assert_true(MathMLFeatureDetection.has_operator_spacing());
let bbox = getBox("largeop");
let hit = document.getElementById("largeop");
let reference = getBox("reference");
assert_true(bbox.height > reference.height, "height of large op is bigger than the equivalent normal operator");
assert_equals(hit, document.elementFromPoint(bbox.left + 1, bbox.top + 1), "hit testing top-left corner of large op works");
assert_equals(hit, document.elementFromPoint(bbox.right - 1, bbox.bottom - 1), "hit testing bottom-right corner of large op works");
}, "Large op hit testing");
done();
}
</script>
</head>
<body>
<math>
<mtable>
<mtr>
<mtd>
<mstyle displaystyle="false">
<mo id="reference">&#x2AFF;</mo>
</mstyle>
</mtd>
<mtd>
<mstyle displaystyle="true">
<mo id="largeop">&#x2AFF;</mo>
</mstyle>
</mtd>
</mtr>
</mtable>
</math>
</body>
</html>

Просмотреть файл

@ -1,18 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8"/>
<title>Padding/border/margin on largeop (reference)</title>
<body>
<p>This test passes if you see a cyan rectangle of width 300px and
height 1500px, surrounded by a 10px blue padding, surrounded by a 10px
blue/yellow dashed border, itself
surrounded by a 10px pink margin.</p>
</div>
<div style="background: pink; position: absolute; left: 10px; top: 4em;">
<div style="background: blue; border: 10px dashed yellow; padding: 10px; margin: 10px;">
<div style="width: 300px; height: 1500px; background: cyan;"></div>
</div>
</div>
</body>
</html>

Просмотреть файл

@ -1,34 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8"/>
<title>Padding/border/margin on largeop</title>
<link rel="help" href="https://mathml-refresh.github.io/mathml-core/#layout-algorithms">
<link rel="help" href="https://mathml-refresh.github.io/mathml-core/#the-math-style-property">
<link rel="help" href="https://mathml-refresh.github.io/mathml-core/#layout-of-operators">
<link rel="match" href="padding-border-margin-002-ref.html"/>
<meta name="assert" content="Verify visual rendering of padding/border/margin on a displaystyle mo element with the largeop property.">
<style>
@font-face {
font-family: TestFont;
src: url("/fonts/math/largeop-displayoperatorminheight5000.woff");
}
math {
/* Largeop variant for U+2AFF has width 100px
and height 300 * 5000 / 1000 = 1500px */
font-family: TestFont;
font-size: 300px;
}
</style>
<body>
<p>This test passes if you see a cyan rectangle of width 300px and
height 1500px, surrounded by a 10px blue padding, surrounded by a 10px
blue/yellow dashed border, itself
surrounded by a 10px pink margin.</p>
<div style="background: pink; position: absolute; left: 10px; top: 4em;">
<math displaystyle="true">
<mo largeop="true" lspace="0" rspace="0" style="background: blue; border: 10px dashed yellow; padding: 10px; margin: 10px; color: cyan;">&#x2AFF;</mo>
</math>
</div>
</body>
</html>