Skip to content

Commit 107e4be

Browse files
committed
[css-text-4] Match closing-opening bracket pair trimming to JLREQ per #1668. Issue remains open for discussion around mismatched font sizes.
1 parent 2357b3d commit 107e4be

File tree

1 file changed

+14
-4
lines changed

1 file changed

+14
-4
lines changed

css-text-4/Overview.bs

+14-4
Original file line numberDiff line numberDiff line change
@@ -1110,6 +1110,7 @@ Fullwidth Punctuation Collapsing</h4>
11101110
Set <a>fullwidth opening punctuation</a> half-width if the previous character is
11111111
a <a>fullwidth opening punctuation</a>,
11121112
<a>fullwidth middle dot punctuation</a>,
1113+
<a>fullwidth closing punctuation</a>,
11131114
or ideographic space (U+3000).
11141115
Else set it full-width.
11151116
<li>
@@ -1118,16 +1119,25 @@ Fullwidth Punctuation Collapsing</h4>
11181119
<a>fullwidth middle dot punctuation</a>,
11191120
or ideographic space (U+3000).
11201121
Else set it full-width.
1121-
<li>
1122-
Set <a>fullwidth closing punctuation</a> followed by <a>fullwidth opening punctuation</a>
1123-
each at "3/4-width", i.e. halfway between full-width and half-width.
11241122
</ul>
11251123

1124+
ISSUE: The above handling of opening&mdash;closing bracket pairs
1125+
matches [[JLREQ]]
1126+
but does not correctly handle the case of mismatched font sizes.
1127+
Earlier drafts trimmed 1/4 of each character, essentially averaging the spacing.
1128+
Other options are possible: use smallest, use largest, use common ancestor (like 'letter-spacing')...
1129+
See <a href="https://github.com/w3c/csswg-drafts/issues/1668#issuecomment-320212394">issue/discussion</a>.
1130+
11261131
<div class="example">
11271132
The following example table lists the punctuation pairs
11281133
affected by adjancent-pairs trimming.
11291134
It uses halfwidth equivalents to approximate the trimming effect.
11301135

1136+
<style>
1137+
.char { border: 1px dotted gray; }
1138+
.quarter { font-size: 25%; }
1139+
samp[lang="ja"] { font-family: "MS Gothic", "Osaka-Mono", monospace }
1140+
</style>
11311141
<table class="data">
11321142
<caption>Demonstration of adjacent-pairs punctuation trimming</caption>
11331143
<thead>
@@ -1143,7 +1153,7 @@ Fullwidth Punctuation Collapsing</h4>
11431153
<td><samp lang="ja" class="char"></samp><samp lang="ja" class="char">(</samp>
11441154
<tr><th scope=row>Closing&#8212;Opening
11451155
<td><samp lang="ja" class="char"></samp>+<samp lang="ja" class="char"></samp>
1146-
<td><samp lang="ja" class="char">)<span class="quarter">&#x3000;</span></samp><samp lang="ja" class="char"><span class="quarter">&#x3000;</span>(</samp>
1156+
<td><samp lang="ja" class="char"></samp><samp lang="ja" class="char">(</samp>
11471157
<tr><th scope=row>Ideographic Space&#8212;Opening
11481158
<td><samp lang="ja" class="char"> </samp>+<samp lang="ja" class="char"></samp>
11491159
<td><samp lang="ja" class="char"> </samp><samp lang="ja" class="char">(</samp>

0 commit comments

Comments
 (0)