Skip to content

Commit afb46d4

Browse files
committed
[css3-writing-modes] Improvements to character orientation rules; clarify that appendix B only covers HTML4
--HG-- extra : rebase_source : e377348fa5d075b0a6fe89549e18ee913f9ce44b
1 parent 6fe9b06 commit afb46d4

2 files changed

Lines changed: 61 additions & 31 deletions

File tree

css3-writing-modes/Overview.html

Lines changed: 33 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -357,7 +357,8 @@ <h2 class="no-num no-toc" id=Contents> Table of Contents</h2>
357357
<li class=no-num><a href="#character-properties">Appendix A. Characters
358358
and Properties</a>
359359

360-
<li class=no-num><a href="#bidi-html"> Appendix B: Bidi Rules for HTML</a>
360+
<li class=no-num><a href="#bidi-html"> Appendix B: Bidi Rules for HTML
361+
4</a>
361362

362363
<li class=no-num><a href="#script-orientations">Appendix C: Vertical
363364
Scripts in Unicode</a>
@@ -1931,17 +1932,21 @@ <h3 id=text-orientation><span class=secno>5.1. </span> Orienting Text: the
19311932
<h4 id=vertical-orientations><span class=secno>5.1.1. </span> Mixed
19321933
Vertical Orientations</h4>
19331934

1934-
<p> <a href="#UTR50" rel=biblioentry>[UTR50]<!--{{!UTR50}}--></a> defines
1935-
the "mixed vertical orientation" (MVO) property in UCD format <a
1936-
href="#UAX44" rel=biblioentry>[UAX44]<!--{{!UAX44}}--></a>. When ‘<a
1937-
href="#text-orientation0"><code
1935+
<p> <a href="#UTR50" rel=biblioentry>[UTR50]<!--{{!UTR50}}--></a> defines a
1936+
property for the default character orientation of mixed-orientation
1937+
vertical text. When ‘<a href="#text-orientation0"><code
19381938
class=property>text-orientation</code></a>’ is ‘<a
19391939
href="#mixed-right"><code class=css>mixed-right</code></a>’, the UA must
1940-
render a <a href="#character"><i>character</i></a> upright if the MVO
1941-
value is ‘<code class=css>U</code>’, ‘<code class=css>T</code>’,
1942-
<code class=css>Tu</code>’, or ‘<code class=css>Tr</code>’, or
1943-
else sideways (90° clockwise from horizontal) if ‘<code
1944-
class=css>R</code>’.
1940+
render a <a href="#character"><i>character</i></a> upright if its
1941+
orientation property is <code>U</code>, <code>T</code>, or
1942+
<code>Tu</code>; or <a href="#typeset-sideways">typeset it sideways</a>
1943+
(90° clockwise from horizontal) if its orientation property is
1944+
<code>R</code>. For <code>Tr</code> <a
1945+
href="#character"><i>characters</i></a>, which are intended to be either
1946+
transformed or rotated sideways, the UA may assume that appropriate glyphs
1947+
for upright typesetting are given in the font and render them upright;
1948+
alternately it may check for such glyphs first, and fall back to
1949+
typesetting them sideways if the appropriate glyphs are missing.
19451950

19461951
<p class=issue> As of the time of publication, Unicode has not yet
19471952
officially updated its orientation data to account for the many errata
@@ -1969,15 +1974,6 @@ <h4 id=vertical-font-features><span class=secno>5.1.2. </span> Vertical
19691974
class=css>vert</code>’ feature must be enabled.) Furthermore,
19701975
characters from horizontal cursive scripts (such as Arabic) are shaped in
19711976
their isolated forms when typeset upright.
1972-
<p class=note> Note that in OpenType systems, <a
1973-
href="#character"><i>characters</i></a> from the Mongolian and Phags-pa
1974-
scripts must actually be rendered <a
1975-
href="#typeset-sideways">sideways</a>. This is because the "upright"
1976-
orientation in the Unicode code charts (which assume vertical
1977-
typesetting) and the "upright" orientation of the glyphs of these
1978-
scripts in most OpenType fonts (which assume horizontal typesetting)
1979-
don't match.
1980-
19811977
<p class=note>Note that even when typeset "upright", some glyphs should
19821978
appear rotated. For example, dashes and enclosing punctuation (such as
19831979
〈 LEFT ANGLE BRACKET U+3008) should be oriented relative to the inline
@@ -1993,6 +1989,16 @@ <h4 id=vertical-font-features><span class=secno>5.1.2. </span> Vertical
19931989
revisions of <a href="#UTR50"
19941990
rel=biblioentry>[UTR50]<!--{{!UTR50}}--></a>.
19951991

1992+
<p> In some font systems (e.g. OpenType), to correctly render a <a
1993+
href="#character"><i>character</i></a> belonging to the Mongolian or
1994+
Phags-pa script upright, the UA must actually typeset it <a
1995+
href="#typeset-sideways">sideways</a>.
1996+
1997+
<p class=note>This is because the "upright" orientation in the Unicode
1998+
code charts (which assume vertical typesetting) and the "upright"
1999+
orientation of the glyphs of these scripts in most OpenType fonts (which
2000+
assume horizontal typesetting) don't match.
2001+
19962002
<dt id=typeset-sideways>sideways characters
19972003

19982004
<dd> Are typeset with horizontal metrics, and vertical typesetting
@@ -2013,6 +2019,13 @@ <h4 id=vertical-font-features><span class=secno>5.1.2. </span> Vertical
20132019
glyph variations, and any other features meant for text typeset in
20142020
vertical lines are <em>not</em> used.
20152021

2022+
<p class=note> The OpenType ‘<code class=css>vrt2</code>’ feature,
2023+
which is intended for mixed-orientation typesetting, is not used by CSS.
2024+
It delegates the responsibility for orienting glyphs to the font designer.
2025+
CSS instead dictates the orientation through <a href="#UTR50"
2026+
rel=biblioentry>[UTR50]<!--{{!UTR50}}--></a> and orients glyphs by
2027+
typesetting them sideways or upright as appropriate.
2028+
20162029
<p class=issue>This section needs additional work. Suggestions are welcome.
20172030
<!-- random notes
20182031
Property to customize text-orientation (and line breaking class) of various
@@ -3755,7 +3768,7 @@ <h2 class=no-num id=character-properties>Appendix A. Characters and
37553768
from the first combining character in the sequence.
37563769
</ul>
37573770

3758-
<h2 class=no-num id=bidi-html> Appendix B: Bidi Rules for HTML</h2>
3771+
<h2 class=no-num id=bidi-html> Appendix B: Bidi Rules for HTML 4</h2>
37593772

37603773
<p>The style sheet rules that would achieve the bidi behaviors specified in
37613774
<a href="#HTML401" rel=biblioentry>[HTML401]<!--{{HTML401}}--></a> for the

css3-writing-modes/Overview.src.html

Lines changed: 28 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1354,10 +1354,18 @@ <h4 id='vertical-orientations'>
13541354
Mixed Vertical Orientations</h4>
13551355

13561356
<p>
1357-
[[!UTR50]] defines the "mixed vertical orientation" (MVO) property in UCD format [[!UAX44]].
1357+
[[!UTR50]] defines a property for the default character orientation of mixed-orientation vertical text.
13581358
When 'text-orientation' is ''mixed-right'',
1359-
the UA must render a <i>character</i> upright if the MVO value is ''U'', ''T'', ''Tu'', or ''Tr'',
1360-
or else sideways (90&deg; clockwise from horizontal) if ''R''.
1359+
the UA must render a <i>character</i> upright if its orientation property is
1360+
<code>U</code>, <code>T</code>, or <code>Tu</code>;
1361+
or <a href="#typeset-sideways">typeset it sideways</a> (90&deg; clockwise from horizontal)
1362+
if its orientation property is <code>R</code>.
1363+
For <code>Tr</code> <i>characters</i>,
1364+
which are intended to be either transformed or rotated sideways,
1365+
the UA may assume that appropriate glyphs for upright typesetting
1366+
are given in the font and render them upright;
1367+
alternately it may check for such glyphs first,
1368+
and fall back to typesetting them sideways if the appropriate glyphs are missing.
13611369

13621370
<p class='issue'>
13631371
As of the time of publication,
@@ -1383,13 +1391,6 @@ <h4 id='vertical-font-features'>
13831391
(E.g. the OpenType ''vert'' feature must be enabled.)
13841392
Furthermore, characters from horizontal cursive scripts (such as Arabic)
13851393
are shaped in their isolated forms when typeset upright.
1386-
<p class="note">
1387-
Note that in OpenType systems,
1388-
<i>characters</i> from the Mongolian and Phags-pa scripts
1389-
must actually be rendered <a href="#typeset-sideways">sideways</a>.
1390-
This is because the "upright" orientation in the Unicode code charts (which assume vertical typesetting)
1391-
and the "upright" orientation of the glyphs of these scripts in most OpenType fonts (which assume horizontal typesetting)
1392-
don't match.
13931394
<p class="note">Note that even when typeset "upright",
13941395
some glyphs should appear rotated.
13951396
For example, dashes and enclosing punctuation
@@ -1402,6 +1403,15 @@ <h4 id='vertical-font-features'>
14021403
Unicode published draft data on which <i>characters</i> should appear sideways
14031404
as the SVO property in <a href="http://www.unicode.org/reports/tr50/tr50-6.Orientation.txt">this data file</a>;
14041405
however, this property has been abandoned for future revisions of [[!UTR50]].
1406+
<p>
1407+
In some font systems (e.g. OpenType),
1408+
to correctly render a <i>character</i> belonging to the Mongolian or Phags-pa script upright,
1409+
the UA must actually typeset it <a href="#typeset-sideways">sideways</a>.
1410+
<p class="note">This is because the "upright" orientation
1411+
in the Unicode code charts (which assume vertical typesetting)
1412+
and the "upright" orientation of the glyphs of these scripts
1413+
in most OpenType fonts (which assume horizontal typesetting)
1414+
don't match.
14051415

14061416
<dt id='typeset-sideways'>sideways characters
14071417
<dd>
@@ -1423,6 +1433,13 @@ <h4 id='vertical-font-features'>
14231433
Vertical metrics, vertical glyph variations, and any other features meant
14241434
for text typeset in vertical lines are <em>not</em> used.
14251435

1436+
<p class="note">
1437+
The OpenType ''vrt2'' feature, which is intended for mixed-orientation typesetting,
1438+
is not used by CSS.
1439+
It delegates the responsibility for orienting glyphs to the font designer.
1440+
CSS instead dictates the orientation through [[!UTR50]]
1441+
and orients glyphs by typesetting them sideways or upright as appropriate.
1442+
14261443
<p class=issue>This section needs additional work. Suggestions are welcome.
14271444

14281445
<!-- random notes
@@ -2879,7 +2896,7 @@ <h2 id="character-properties" class="no-num">Appendix A.
28792896
</ul>
28802897

28812898
<h2 id="bidi-html" class=no-num>
2882-
Appendix B: Bidi Rules for HTML</h2>
2899+
Appendix B: Bidi Rules for HTML 4</h2>
28832900

28842901
<p>The style sheet rules that would achieve the bidi behaviors specified
28852902
in [[HTML401]] for the HTML Strict doctype are given below:

0 commit comments

Comments
 (0)