Bug 1097499 part 15 - Add reftests for text-combine-upright. r=jfkthame

MozReview-Commit-ID: 2PhaUnUMF5l

--HG--
extra : source : 407f4b5e701aa1aab7830dd3298ead2b37b349bf
This commit is contained in:
Xidorn Quan 2016-04-22 09:18:41 +10:00
Родитель f819b73b7b
Коммит a6096a3c0b
21 изменённых файлов: 398 добавлений и 0 удалений

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

@ -78,3 +78,6 @@ include variables/reftest.list
# CSS will-change Level 1
include will-change/reftest.list
# CSS Writing Modes Level 3
include writing-modes-3/reftest.list

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

@ -0,0 +1,11 @@
default-preferences pref(layout.css.text-combine-upright.enabled,true)
== text-combine-upright-compression-001.html text-combine-upright-compression-001-ref.html
== text-combine-upright-compression-002.html text-combine-upright-compression-002-ref.html
== text-combine-upright-compression-003.html text-combine-upright-compression-003-ref.html
== text-combine-upright-compression-004.html text-combine-upright-compression-004-ref.html
== text-combine-upright-compression-005.html text-combine-upright-compression-005-ref.html
== text-combine-upright-compression-005a.html text-combine-upright-compression-005-ref.html
== text-combine-upright-compression-006.html text-combine-upright-compression-006-ref.html
== text-combine-upright-compression-006a.html text-combine-upright-compression-006-ref.html
== text-combine-upright-compression-007.html text-combine-upright-compression-007-ref.html

Двоичный файл не отображается.

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

@ -0,0 +1,11 @@
.tcy {
text-combine-upright: all;
}
.fake-tcy {
display: inline-block;
writing-mode: horizontal-tb;
width: 1em;
height: 1em;
text-align: center;
line-height: 1em;
}

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

@ -0,0 +1,7 @@
@font-face {
font-family: WidthTest;
src: url(WidthTest-Regular.otf);
}
.test {
font: 72px/1 WidthTest;
}

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

@ -0,0 +1,21 @@
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<title>CSS Reference: text-combine-upright, no compression</title>
<link rel="author" href="Xidorn Quan" href="https://www.upsuper.org">
<link rel="stylesheet" href="support/width-test.css">
<link rel="stylesheet" href="support/tcy.css">
<style>
.test { writing-mode: vertical-rl; }
.test > p { border: 1px solid black; }
</style>
</head>
<body>
<p>Test passes if there are two identical zeros in the blocks below.</p>
<div class="test">
<p><span class="fake-tcy">0</span></p>
<p><span class="fake-tcy">0</span></p>
</div>
</body>
</html>

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

@ -0,0 +1,24 @@
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<title>CSS Test: text-combine-upright, no compression</title>
<link rel="author" href="Xidorn Quan" href="https://www.upsuper.org">
<link rel="help" href="https://drafts.csswg.org/css-writing-modes-3/#text-combine-compression">
<link rel="match" href="text-combine-upright-compression-001-ref.html">
<meta name="assert" href="text-combine-upright with character not wider than 1em should not trigger compression.">
<link rel="stylesheet" href="support/width-test.css">
<link rel="stylesheet" href="support/tcy.css">
<style>
.test { writing-mode: vertical-rl; }
.test > p { border: 1px solid black; }
</style>
</head>
<body>
<p>Test passes if there are two identical zeros in the blocks below.</p>
<div class="test">
<p><span class="tcy">0</span></p>
<p><span class="fake-tcy">0</span></p>
</div>
</body>
</html>

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

@ -0,0 +1,21 @@
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<title>CSS Reference: text-combine-upright, compression of two characters</title>
<link rel="author" href="Xidorn Quan" href="https://www.upsuper.org">
<link rel="stylesheet" href="support/width-test.css">
<link rel="stylesheet" href="support/tcy.css">
<style>
.test { writing-mode: vertical-rl; }
.test > p { border: 1px solid black; }
</style>
</head>
<body>
<p>Test passes if there are two identical graphs in the blocks below.</p>
<div class="test">
<p><span class="fake-tcy">22</span></p>
<p><span class="fake-tcy">22</span></p>
</div>
</body>
</html>

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

@ -0,0 +1,24 @@
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<title>CSS Test: text-combine-upright, compression of two characters</title>
<link rel="author" href="Xidorn Quan" href="https://www.upsuper.org">
<link rel="help" href="https://drafts.csswg.org/css-writing-modes-3/#text-combine-compression">
<link rel="match" href="text-combine-upright-compression-002-ref.html">
<meta name="assert" href="text-combine-upright should try applying 'hwid' feature if the width is wider than 1em">
<link rel="stylesheet" href="support/width-test.css">
<link rel="stylesheet" href="support/tcy.css">
<style>
.test { writing-mode: vertical-rl; }
.test > p { border: 1px solid black; }
</style>
</head>
<body>
<p>Test passes if there are two identical graphs in the blocks below.</p>
<div class="test">
<p><span class="tcy">00</span></p>
<p><span class="fake-tcy">22</span></p>
</div>
</body>
</html>

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

@ -0,0 +1,21 @@
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<title>CSS Reference: text-combine-upright, compression of three characters</title>
<link rel="author" href="Xidorn Quan" href="https://www.upsuper.org">
<link rel="stylesheet" href="support/width-test.css">
<link rel="stylesheet" href="support/tcy.css">
<style>
.test { writing-mode: vertical-rl; }
.test > p { border: 1px solid black; }
</style>
</head>
<body>
<p>Test passes if there are two identical graphs in the blocks below.</p>
<div class="test">
<p><span class="fake-tcy">333</span></p>
<p><span class="fake-tcy">333</span></p>
</div>
</body>
</html>

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

@ -0,0 +1,24 @@
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<title>CSS Test: text-combine-upright, compression of three characters</title>
<link rel="author" href="Xidorn Quan" href="https://www.upsuper.org">
<link rel="help" href="https://drafts.csswg.org/css-writing-modes-3/#text-combine-compression">
<link rel="match" href="text-combine-upright-compression-003-ref.html">
<meta name="assert" href="text-combine-upright should try applying 'twid' feature if the width is wider than 1em">
<link rel="stylesheet" href="support/width-test.css">
<link rel="stylesheet" href="support/tcy.css">
<style>
.test { writing-mode: vertical-rl; }
.test > p { border: 1px solid black; }
</style>
</head>
<body>
<p>Test passes if there are two identical graphs in the blocks below.</p>
<div class="test">
<p><span class="tcy">000</span></p>
<p><span class="fake-tcy">333</span></p>
</div>
</body>
</html>

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

@ -0,0 +1,21 @@
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<title>CSS Reference: text-combine-upright, compression of four characters</title>
<link rel="author" href="Xidorn Quan" href="https://www.upsuper.org">
<link rel="stylesheet" href="support/width-test.css">
<link rel="stylesheet" href="support/tcy.css">
<style>
.test { writing-mode: vertical-rl; }
.test > p { border: 1px solid black; }
</style>
</head>
<body>
<p>Test passes if there are two identical graphs in the blocks below.</p>
<div class="test">
<p><span class="fake-tcy">4444</span></p>
<p><span class="fake-tcy">4444</span></p>
</div>
</body>
</html>

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

@ -0,0 +1,24 @@
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<title>CSS Test: text-combine-upright, compression of four characters</title>
<link rel="author" href="Xidorn Quan" href="https://www.upsuper.org">
<link rel="help" href="https://drafts.csswg.org/css-writing-modes-3/#text-combine-compression">
<link rel="match" href="text-combine-upright-compression-004-ref.html">
<meta name="assert" href="text-combine-upright should try applying 'qwid' feature if the width is wider than 1em">
<link rel="stylesheet" href="support/width-test.css">
<link rel="stylesheet" href="support/tcy.css">
<style>
.test { writing-mode: vertical-rl; }
.test > p { border: 1px solid black; }
</style>
</head>
<body>
<p>Test passes if there are two identical graphs in the blocks below.</p>
<div class="test">
<p><span class="tcy">0000</span></p>
<p><span class="fake-tcy">4444</span></p>
</div>
</body>
</html>

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

@ -0,0 +1,21 @@
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<title>CSS Reference: text-combine-upright, no compression for single full-width character</title>
<link rel="author" href="Xidorn Quan" href="https://www.upsuper.org">
<link rel="stylesheet" href="support/width-test.css">
<link rel="stylesheet" href="support/tcy.css">
<style>
.test { writing-mode: vertical-rl; }
.test > p { border: 1px solid black; }
</style>
</head>
<body>
<p>Test passes if there are two identical graphs in the blocks below.</p>
<div class="test">
<p><span class="fake-tcy"></span></p>
<p><span class="fake-tcy"></span></p>
</div>
</body>
</html>

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

@ -0,0 +1,24 @@
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<title>CSS Test: text-combine-upright, no compression for single full-width character</title>
<link rel="author" href="Xidorn Quan" href="https://www.upsuper.org">
<link rel="help" href="https://drafts.csswg.org/css-writing-modes-3/#text-combine-fullwidth">
<link rel="match" href="text-combine-upright-compression-005-ref.html">
<meta name="assert" href="text-combine-upright should not change a single full-width character">
<link rel="stylesheet" href="support/width-test.css">
<link rel="stylesheet" href="support/tcy.css">
<style>
.test { writing-mode: vertical-rl; }
.test > p { border: 1px solid black; }
</style>
</head>
<body>
<p>Test passes if there are two identical graphs in the blocks below.</p>
<div class="test">
<p><span class="tcy"></span></p>
<p><span class="fake-tcy"></span></p>
</div>
</body>
</html>

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

@ -0,0 +1,25 @@
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<title>CSS Test: text-combine-upright, no compression for single character with full-width transform</title>
<link rel="author" href="Xidorn Quan" href="https://www.upsuper.org">
<link rel="help" href="https://drafts.csswg.org/css-writing-modes-3/#text-combine-fullwidth">
<link rel="match" href="text-combine-upright-compression-005-ref.html">
<meta name="assert" href="text-combine-upright should not change a single full-width character">
<link rel="stylesheet" href="support/width-test.css">
<link rel="stylesheet" href="support/tcy.css">
<style>
.test { writing-mode: vertical-rl; }
.test > p { border: 1px solid black; }
.tcy { text-transform: full-width; }
</style>
</head>
<body>
<p>Test passes if there are two identical graphs in the blocks below.</p>
<div class="test">
<p><span class="tcy">0</span></p>
<p><span class="fake-tcy"></span></p>
</div>
</body>
</html>

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

@ -0,0 +1,21 @@
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<title>CSS Reference: text-combine-upright, compression for two full-width characters</title>
<link rel="author" href="Xidorn Quan" href="https://www.upsuper.org">
<link rel="stylesheet" href="support/width-test.css">
<link rel="stylesheet" href="support/tcy.css">
<style>
.test { writing-mode: vertical-rl; }
.test > p { border: 1px solid black; }
</style>
</head>
<body>
<p>Test passes if there are two identical graphs in the blocks below.</p>
<div class="test">
<p><span class="fake-tcy">22</span></p>
<p><span class="fake-tcy">22</span></p>
</div>
</body>
</html>

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

@ -0,0 +1,24 @@
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<title>CSS Test: text-combine-upright, compression for two full-width characters</title>
<link rel="author" href="Xidorn Quan" href="https://www.upsuper.org">
<link rel="help" href="https://drafts.csswg.org/css-writing-modes-3/#text-combine-fullwidth">
<link rel="match" href="text-combine-upright-compression-006-ref.html">
<meta name="assert" href="text-combine-upright should run the reverse of full-width transform before applying compression">
<link rel="stylesheet" href="support/width-test.css">
<link rel="stylesheet" href="support/tcy.css">
<style>
.test { writing-mode: vertical-rl; }
.test > p { border: 1px solid black; }
</style>
</head>
<body>
<p>Test passes if there are two identical graphs in the blocks below.</p>
<div class="test">
<p><span class="tcy"></span></p>
<p><span class="fake-tcy">22</span></p>
</div>
</body>
</html>

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

@ -0,0 +1,25 @@
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<title>CSS Test: text-combine-upright, compression for two characters with full-width transform</title>
<link rel="author" href="Xidorn Quan" href="https://www.upsuper.org">
<link rel="help" href="https://drafts.csswg.org/css-writing-modes-3/#text-combine-fullwidth">
<link rel="match" href="text-combine-upright-compression-006-ref.html">
<meta name="assert" href="text-combine-upright should run the reverse of full-width transform before applying compression">
<link rel="stylesheet" href="support/width-test.css">
<link rel="stylesheet" href="support/tcy.css">
<style>
.test { writing-mode: vertical-rl; }
.test > p { border: 1px solid black; }
.tcy { text-transform: full-width; }
</style>
</head>
<body>
<p>Test passes if there are two identical graphs in the blocks below.</p>
<div class="test">
<p><span class="tcy">00</span></p>
<p><span class="fake-tcy">22</span></p>
</div>
</body>
</html>

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

@ -0,0 +1,21 @@
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<title>CSS Reference: text-combine-upright: all, fit any number of characters</title>
<link rel="author" href="Xidorn Quan" href="https://www.upsuper.org">
<link rel="stylesheet" href="support/width-test.css">
<link rel="stylesheet" href="support/tcy.css">
<style>
.test { writing-mode: vertical-rl; height: 3.5em; }
.test > p { border: 1px solid black; }
</style>
</head>
<body>
<p>Test passes if the contents in the two blocks are identical.</p>
<div class="test">
<p><span class="fake-tcy"></span></p>
<p><span class="fake-tcy"></span></p>
</div>
</body>
</html>

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

@ -0,0 +1,25 @@
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<title>CSS Test: text-combine-upright: all, fit any number of characters</title>
<link rel="author" href="Xidorn Quan" href="https://www.upsuper.org">
<link rel="help" href="https://drafts.csswg.org/css-writing-modes-3/#text-combine-compression">
<link rel="match" href="text-combine-upright-compression-001-ref.html">
<meta name="assert" href="text-combine-upright: all should allow any amount of text to be compressed in a 1em square">
<link rel="stylesheet" href="support/width-test.css">
<link rel="stylesheet" href="support/tcy.css">
<style>
.test { writing-mode: vertical-rl; height: 3.5em; }
.test > p { border: 1px solid black; }
.tcy { color: transparent; }
</style>
</head>
<body>
<p>Test passes if the contents in the two blocks are identical.</p>
<div class="test">
<p><span class="tcy">ニ三四五六七八九</span></p>
<p><span class="fake-tcy"></span></p>
</div>
</body>
</html>