Skip to content

Commit ec1d677

Browse files
committed
Editorial edits to white space processing rules, cut out a paragraph that's no longer relevant and update informative summary to match previous substantive edits; also fix a text-justify example
1 parent 28c04da commit ec1d677

2 files changed

Lines changed: 77 additions & 94 deletions

File tree

css3-text/Overview.html

Lines changed: 48 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -83,15 +83,15 @@
8383

8484
<h1>CSS Text Level 3</h1>
8585

86-
<h2 class="no-num no-toc" id=longstatus-date>Editor's Draft 19 February
86+
<h2 class="no-num no-toc" id=longstatus-date>Editor's Draft 23 February
8787
2011</h2>
8888

8989
<dl>
9090
<dt>This version:
9191

9292
<dd><a href="http://dev.w3.org/csswg/css3-text/Overview.html">$Date:
93-
2011/02/14 11:42:29 $ (CVS $Revision$)</a> <!--
94-
<dd><a href="http://www.w3.org/TR/2011/WD-css3-text-20110219/">http://www.w3.org/TR/2011/WD-css3-text-20110219/</a></dd>
93+
2011/02/19 14:54:46 $ (CVS $Revision$)</a> <!--
94+
<dd><a href="http://www.w3.org/TR/2011/WD-css3-text-20110223/">http://www.w3.org/TR/2011/WD-css3-text-20110223/</a></dd>
9595
-->
9696

9797

@@ -366,7 +366,7 @@ <h2 class="no-num no-toc" id=contents>Table of Contents</h2>
366366
Kerning: the &lsquo;<code class=property>text-trim</code>&rsquo;
367367
property</a>
368368

369-
<li><a href="#text-autospace"><span class=secno>9.4. </span> Adding
369+
<li><a href="#text-autospace-prop"><span class=secno>9.4. </span> Adding
370370
space: the &lsquo;<code class=property>text-autospace</code>&rsquo;
371371
property</a>
372372
</ul>
@@ -663,7 +663,7 @@ <h3 id=text-transform><span class=secno>3.1. </span> <a name=caps-prop></a>
663663
title="text-transform:fullwidth"><code>fullwidth</code></dfn>
664664

665665
<dd>Puts all characters in fullwidth form. If the character does not have
666-
corresponding fullwidth form, it is left as is. This value is typically
666+
a corresponding fullwidth form, it is left as is. This value is typically
667667
used to typeset Latin characters and digits like ideographic characters.
668668

669669
<dt><dfn id=large-kana
@@ -709,21 +709,21 @@ <h2 id=white-space-processing><span class=secno>4. </span> White Space
709709
allows the author to control interpretation of such formatting: to
710710
preserve or collapse it away when rendering the document.
711711

712-
<p>Segments in the document source can be separated by a carriage return
713-
(U+000D), a linefeed (U+000A) or both (U+000D U+000A), or by some other
714-
mechanism that identifies the beginning and end of document segments, such
715-
as the SGML RECORD-START and RECORD-END tokens. If no segmentation rules
716-
are specified for the document language, each line feed (U+000A), carriage
717-
return (U+000D) and CRLF sequence (U+000D U+000A) in the text is
718-
considered a segment break. (This default rule also applies to generated
719-
content.) In CSS, each such segment break is treated as a single line feed
720-
character (U+000A).
721-
722712
<p>White space processing in CSS interprets white space characters for
723-
rendering: it has no effect on the underlying document data. In the
724-
context of CSS, the document white space set is defined to be any space
725-
characters (Unicode value U+0020), tab characters (U+0009), and line feeds
726-
(U+000A).
713+
rendering: it has no effect on the underlying document data.
714+
715+
<p>In the context of CSS, the document white space set is defined to be any
716+
space characters (Unicode value U+0020), tab characters (U+0009), and line
717+
feeds (U+000A).
718+
719+
<p>However in the document source, segments can be delimited by carriage
720+
returns (U+000D), linefeeds (U+000A) or a combination (U+000D U+000A), or
721+
by some other mechanism, such as the SGML RECORD-START and RECORD-END
722+
tokens. In CSS, each such segment break is treated as a single line feed
723+
character (U+000A). If no segmentation rules are specified for the
724+
document language, each line feed (U+000A), carriage return (U+000D) and
725+
CRLF sequence (U+000D U+000A) in the text is considered a segment break.
726+
(This default rule also applies to generated content.)
727727

728728
<p class=note>Note that the document parser may have not only normalized
729729
segment breaks, but also collapsed other space characters or otherwise
@@ -810,14 +810,14 @@ <h3 id=white-space-collapsing><span class=secno>4.1. </span> White Space
810810
title="white-space-collapsing:preserve"><code>preserve</code></dfn>
811811

812812
<dd>This value prevents user agents from collapsing sequences of white
813-
space. Segment breaks are preserved as forced line breaks.
813+
space. Line feeds are preserved as forced line breaks.
814814

815815
<dt><dfn id=preserve-breaks
816816
title="white-space-collapsing:preserve-breaks"><code>preserve-breaks</code></dfn>
817817

818818
<dd>This value collapses white space as for &lsquo;<code
819-
class=css>collapse</code>&rsquo;, but preserves segment breaks as forced
820-
line breaks.
819+
class=css>collapse</code>&rsquo;, but preserves line feeds as forced line
820+
breaks.
821821

822822
<dt><dfn id=discard
823823
title="white-space-collapsing:discard"><code>discard</code></dfn>
@@ -829,9 +829,9 @@ <h3 id=white-space-collapsing><span class=secno>4.1. </span> White Space
829829
title="white-space-collapsing:trim-inner"><code>trim-inner</code></dfn>
830830

831831
<dd>This value directs UAs to discard all whitespace at the beginning of a
832-
block up to and including the last line break before the first
832+
block up to and including the last line feed before the first
833833
non-white-space character in the block as well as to discard all white
834-
space at the end of a block starting with the first line break after the
834+
space at the end of a block starting with the first line feed after the
835835
last non-white-space character in the block.
836836
</dl>
837837

@@ -853,10 +853,8 @@ <h3 id=white-space-rules><span class=secno>4.2. </span> The White Space
853853
performing the following steps:</p>
854854

855855
<ol>
856-
<li>All spaces and tabs immediately following a line feed character are
857-
removed. (This has the effect of discarding all white space at the
858-
start of a line but preserving a trailing space if one exists at the
859-
end.)
856+
<li>All spaces and tabs immediately preceding or following a line feed
857+
character are removed.
860858

861859
<li>If <span class=property>&lsquo;<a
862860
href="#white-space-collapsing0"><code
@@ -917,6 +915,10 @@ <h3 id=white-space-rules><span class=secno>4.2. </span> The White Space
917915
class=property>avoid</code>&rsquo; the UA may visually collapse them.
918916
</ol>
919917

918+
<p class=issue>There was a proposal for a &lsquo;<code
919+
class=property>tab-size</code>&rsquo; property to control the size of tab
920+
stops. Is there implementation interest in this property?
921+
920922
<div class=example>
921923
<h4 id=egbidiwscollapse><span class=secno>4.2.1. </span> Example of
922924
bidirectionality with white space collapsing</h4>
@@ -964,16 +966,6 @@ <h4 id=line-break-transform><span class=secno>4.2.2. </span> Line Break
964966
transformed into a space (U+0020) or removed depending on the script
965967
context before and after the line break.
966968

967-
<p>The script context is determined by the Unicode-given script value <a
968-
href="#UAX24" rel=biblioentry>[UAX24]<!--{{!UAX24}}--></a> of the first
969-
character that side of the line feed. However, characters such as
970-
punctuation that belong to the COMMON and INHERITED scripts are ignored in
971-
this check; the next character is examined instead. The UA must not
972-
examine characters outside the block and may limit its examination to as
973-
few as four characters on each side of the line feed. If the check fails
974-
to find an acceptable script value (i.e. it has hit the check limits),
975-
then the script context is neutral.
976-
977969
<p class=note>Note that the white space processing rules have already
978970
removed any tabs and spaces after the line feed before these checks take
979971
place.
@@ -991,7 +983,7 @@ <h4 id=line-break-transform><span class=secno>4.2.2. </span> Line Break
991983
and after the line feed is F, W, or H (not A), then the line feed is
992984
removed.
993985

994-
<li>Otherwise, if &lsquo;<a href="#text-autospace0"><code
986+
<li>Otherwise, if &lsquo;<a href="#text-autospace"><code
995987
class=property>text-autospace</code></a>&rsquo; property is set to add
996988
extra spaces for the combination of the character before the line feed
997989
and after, then the line break is removed.
@@ -1009,13 +1001,13 @@ <h4 id=white-space-summary><span class=secno>4.2.3. </span> Informative
10091001
<ul>
10101002
<li>Consecutive white space collapses into a single space.
10111003

1012-
<li>A sequence of line breaks and other white space between two
1013-
ideographic characters collapses into nothing unless there is a space
1014-
before the first line break in the sequence.
1004+
<li>A sequence of newlines and other white space between two ideographic
1005+
characters collapses into nothing unless there is a space before the
1006+
first newline in the sequence.
10151007

1016-
<li>A zero width space immediately before or anywhere after a line break
1017-
causes the entire sequence of white space beginning with the line break
1018-
to collapse into a zero width space.
1008+
<li>A zero width space within a white space sequence containing a newline
1009+
causes the entire sequence of white space to collapse into a zero width
1010+
space.
10191011
</ul>
10201012

10211013
<h3 id=white-space><span class=secno>4.3. </span> White Space and Text
@@ -3168,14 +3160,14 @@ <h3 id=text-justify><span class=secno>8.4. </span> Justification Method:
31683160
behavior is not defined by CSS.
31693161

31703162
<div class=example>
3171-
<p>Japanese is one of the languages for which compression is preferred to
3172-
expansion in applying justification.</p>
3173-
31743163
<p>3.8 Line Adjustment in <a href="#JLREQ"
31753164
rel=biblioentry>[JLREQ]<!--{{JLREQ}}--></a> gives an example of a set of
31763165
rules for how a text formatter can justify Japanese text. It describes
31773166
rules for cases where the &lsquo;<a href="#text-justify0"><code
31783167
class=property>text-justify</code></a>&rsquo; property is &lsquo;<code
3168+
class=css>inter-ideograph</code>&rsquo;. It describes rules for cases
3169+
where the &lsquo;<a href="#text-justify0"><code
3170+
class=property>text-justify</code></a>&rsquo; property is &lsquo;<code
31793171
class=css>inter-ideograph</code>&rsquo; and the &lsquo;<a
31803172
href="#text-trim"><code class=property>text-trim</code></a>&rsquo;
31813173
property does not specify &lsquo;<code
@@ -3772,16 +3764,16 @@ <h3 id=text-trim-prop><span class=secno>9.3. </span> <a
37723764
standard convention is often not followed.</p>
37733765
</div>
37743766

3775-
<h3 id=text-autospace><span class=secno>9.4. </span> <a
3776-
name=text-autospace-prop></a> <a name=text-autospace>Adding space: the
3777-
&lsquo;<code class=property>text-autospace</code>&rsquo; property</a></h3>
3767+
<h3 id=text-autospace-prop><span class=secno>9.4. </span> Adding space: the
3768+
&lsquo;<a href="#text-autospace"><code
3769+
class=property>text-autospace</code></a>&rsquo; property</h3>
37783770

37793771
<table class=propdef>
37803772
<tbody>
37813773
<tr>
37823774
<th>Name:
37833775

3784-
<td><dfn id=text-autospace0>text-autospace</dfn>
3776+
<td><dfn id=text-autospace>text-autospace</dfn>
37853777

37863778
<tr>
37873779
<th>Value:
@@ -5397,13 +5389,13 @@ <h3 class=no-num id=recent-changes> Changes from the <a
53975389

53985390
<li>Removed &lsquo;<code class=css>ideograph-space</code>&rsquo; and
53995391
&lsquo;<code class=css>ideograph-parenthesis</code>&rsquo; values of
5400-
&lsquo;<a href="#text-autospace0"><code
5392+
&lsquo;<a href="#text-autospace"><code
54015393
class=property>text-autospace</code></a>&rsquo;.
54025394

54035395
<li>Changed definitions of <a href="#ideographic-letters">ideographic
54045396
letters</a>, <a href="#non-ideographic-letters">non-ideographic
54055397
letters</a>, and <a href="#non-ideographic-numerals">non-ideographic
5406-
numerals</a> for &lsquo;<a href="#text-autospace0"><code
5398+
numerals</a> for &lsquo;<a href="#text-autospace"><code
54075399
class=property>text-autospace</code></a>&rsquo;.
54085400

54095401
<li>Changed values of &lsquo;<a href="#text-emphasis-position0"><code
@@ -5810,7 +5802,7 @@ <h2 class=no-num id=appendix-b-property-index> Appendix B: Property index</h2>
58105802
<td>visual
58115803

58125804
<tr valign=baseline>
5813-
<td><a class=property href="#text-autospace0">text-autospace</a>
5805+
<td><a class=property href="#text-autospace">text-autospace</a>
58145806

58155807
<td>none | [ ideograph-numeric || ideograph-alpha || punctuation ]
58165808

@@ -6405,7 +6397,7 @@ <h2 class=no-num id=index>Index</h2>
64056397
<li>text-align:&lt;string>, <a href="#ltstringgt"
64066398
title="text-align:&lt;string>"><strong>8.1.</strong></a>
64076399

6408-
<li>text-autospace, <a href="#text-autospace0"
6400+
<li>text-autospace, <a href="#text-autospace"
64096401
title=text-autospace><strong>9.4.</strong></a>
64106402

64116403
<li>text-autospace:ideograph-alpha, <a href="#ideograph-alpha"

css3-text/Overview.src.html

Lines changed: 29 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -350,7 +350,7 @@ <h3 id="text-transform">
350350
<dd>Puts all characters in lowercase.</dd>
351351
<dt><dfn title="text-transform:fullwidth"><code>fullwidth</code></dfn></dt>
352352
<dd>Puts all characters in fullwidth form.
353-
If the character does not have corresponding fullwidth form,
353+
If the character does not have a corresponding fullwidth form,
354354
it is left as is.
355355
This value is typically used to typeset Latin characters and digits
356356
like ideographic characters.
@@ -392,24 +392,24 @@ <h2 id="white-space-processing">
392392
control interpretation of such formatting: to preserve or
393393
collapse it away when rendering the document.
394394

395-
<p>Segments in the document source can be separated by a carriage
396-
return (U+000D), a linefeed (U+000A) or both (U+000D U+000A),
397-
or by some other mechanism that identifies the beginning
398-
and end of document segments, such as the SGML RECORD-START
399-
and RECORD-END tokens.
400-
If no segmentation rules are specified for the document language,
401-
each line feed (U+000A), carriage return (U+000D) and CRLF sequence
402-
(U+000D U+000A) in the text is considered a segment break. (This
403-
default rule also applies to generated content.)
404-
In CSS, each such segment break is treated as a single line feed
405-
character (U+000A).
406-
407395
<p>White space processing in CSS interprets white space characters
408396
for rendering: it has no effect on the underlying document data.
409-
In the context of CSS, the document white space set is defined
397+
398+
<p>In the context of CSS, the document white space set is defined
410399
to be any space characters (Unicode value U+0020), tab characters
411400
(U+0009), and line feeds (U+000A).
412401

402+
<p>However in the document source, segments can be delimited by carriage
403+
returns (U+000D), linefeeds (U+000A) or a combination (U+000D U+000A),
404+
or by some other mechanism, such as the SGML RECORD-START
405+
and RECORD-END tokens. In CSS, each such segment break is treated as
406+
a single line feed character (U+000A).
407+
408+
If no segmentation rules are specified for the document language,
409+
each line feed (U+000A), carriage return (U+000D) and CRLF sequence
410+
(U+000D U+000A) in the text is considered a segment break. (This
411+
default rule also applies to generated content.)
412+
413413
<p class="note">Note that the document parser may have not only normalized
414414
segment breaks, but also collapsed other space characters or
415415
otherwise processed white space according to markup rules. Because CSS
@@ -480,18 +480,18 @@ <h3 id="white-space-collapsing">
480480
cases</a>, no character).</dd>
481481
<dt><dfn title="white-space-collapsing:preserve"><code>preserve</code></dfn></dt>
482482
<dd>This value prevents user agents from collapsing sequences
483-
of white space. Segment breaks are preserved as forced line breaks.</dd>
483+
of white space. Line feeds are preserved as forced line breaks.</dd>
484484
<dt><dfn title="white-space-collapsing:preserve-breaks"><code>preserve-breaks</code></dfn></dt>
485485
<dd>This value collapses white space as for ''collapse'', but preserves
486-
segment breaks as forced line breaks.</dd>
486+
line feeds as forced line breaks.</dd>
487487
<dt><dfn title="white-space-collapsing:discard"><code>discard</code></dfn></dt>
488488
<dd>This value directs user agents to "discard" all white space in the
489489
element.
490490
<dt><dfn title="white-space-collapsing:trim-inner"><code>trim-inner</code></dfn></dt>
491491
<dd>This value directs UAs to discard all whitespace at the beginning of
492-
a block up to and including the last line break before the first
492+
a block up to and including the last line feed before the first
493493
non-white-space character in the block as well as to discard all white
494-
space at the end of a block starting with the first line break after
494+
space at the end of a block starting with the first line feed after
495495
the last non-white-space character in the block.</dd>
496496
</dl>
497497

@@ -508,10 +508,8 @@ <h3 id="white-space-rules">
508508
are considered <dfn>collapsible</dfn> and are processed by
509509
performing the following steps:</p>
510510
<ol>
511-
<li>All spaces and tabs immediately following a line feed character
512-
are removed. (This has the effect of discarding all white space
513-
at the start of a line but preserving a trailing space if one
514-
exists at the end.)</li>
511+
<li>All spaces and tabs immediately preceding or following a line
512+
feed character are removed.</li>
515513
<li>If <span class="property">'white-space-collapsing'</span> is not
516514
'preserve-breaks', line feed characters are transformed for
517515
rendering according to the <a href="#line-break-transform">line
@@ -555,6 +553,9 @@ <h3 id="white-space-rules">
555553
the UA may visually collapse them.
556554
</ol>
557555

556+
<p class="issue">There was a proposal for a 'tab-size' property to control
557+
the size of tab stops. Is there implementation interest in this property?</p>
558+
558559
<div class="example">
559560
<h4 id="egbidiwscollapse">
560561
Example of bidirectionality with white space collapsing</h4>
@@ -600,15 +601,6 @@ <h4 id="line-break-transform">
600601
either transformed into a space (U+0020) or removed depending on the
601602
script context before and after the line break.</p>
602603

603-
<p>The script context is determined by the Unicode-given script value
604-
[[!UAX24]] of the first character that side of the line feed. However,
605-
characters such as punctuation that belong to the COMMON and INHERITED
606-
scripts are ignored in this check; the next character is examined
607-
instead. The UA must not examine characters outside the block and may
608-
limit its examination to as few as four characters on each side of the
609-
line feed. If the check fails to find an acceptable script value
610-
(i.e. it has hit the check limits), then the script context is neutral.</p>
611-
612604
<p class="note">Note that the white space processing rules have already
613605
removed any tabs and spaces after the line feed before these checks
614606
take place.</p>
@@ -637,13 +629,12 @@ <h4 id="white-space-summary">
637629

638630
<ul>
639631
<li>Consecutive white space collapses into a single space.
640-
<li>A sequence of line breaks and other white space between
632+
<li>A sequence of newlines and other white space between
641633
two ideographic characters collapses into nothing unless
642-
there is a space before the first line break in the sequence.
643-
<li>A zero width space immediately before or anywhere after
644-
a line break causes the entire sequence of white space
645-
beginning with the line break to collapse into a zero width
646-
space.
634+
there is a space before the first newline in the sequence.
635+
<li>A zero width space within a white space sequence containing
636+
a newline causes the entire sequence of white space
637+
to collapse into a zero width space.
647638
</ul>
648639

649640
<h3 id="white-space">
@@ -2274,9 +2265,9 @@ <h3 id="text-justify">
22742265
any method. This behavior is not defined by CSS.</p>
22752266

22762267
<div class="example">
2277-
<p>Japanese is one of the languages for which compression is preferred to expansion in applying justification.</p>
22782268
<p>3.8 Line Adjustment in [[JLREQ]] gives an example of a set of rules for
22792269
how a text formatter can justify Japanese text.
2270+
It describes rules for cases where the 'text-justify' property is ''inter-ideograph''.
22802271
It describes rules for cases where the 'text-justify' property is ''inter-ideograph''
22812272
and the 'text-trim' property does not specify ''no-justify''.</p>
22822273
<p>It produces an effect similar to cases where

0 commit comments

Comments
 (0)