RE: Revising text wrapping, line breaking, and white space properties in CSS3 (CSS3 Text: 6 and 7)

And another batch of (personal) comments...

> From: w3c-i18n-wg-request@w3.org 
> [mailto:w3c-i18n-wg-request@w3.org] On Behalf Of fantasai
> Sent: 04 October 2004 17:05

<snip/>

> Proposed:
>    word-break: keep-all | strict | normal | break-all
> 
> Justification:
>    Practically-speaking, there's only one scale of strictness.
>                    strictest <----------------------> loosest
>    line-break     | irrelevant | strict | normal | normal    |
>    word-break-cjk | keep-all   | normal | normal | break-all |
> 
>    * normal vs. strict line-breaking is irrelevant when 
> keep-all takes effect.
>    * The combination of strict and break-all makes little sense. (Why
>      would you allow breaks in scripts like Latin, where 
> breaking words
>      in random places is wrong, but disallow breaks before small kana,
>      where breaking is merely discouraged?)
> 
> Compatibility:
>    wrt XSL -
>      n/a
>    wrt WinIE -
>      The proposal uses the WinIE property name and values. It 
> also adds
>      a new value, 'strict', which will be ignored in WinIE. A 
> style sheet
>      can cause IE to recognize the same effect by also specifying
>      "line-break: strict".

<snip/>

> Text Wrap
> ---------
> 
> CSS3 Text:
>    wrap-option: wrap | no-wrap | soft-wrap | emergency
> 
> XSL:
>    wrap-option: no-wrap | wrap
> 
> WinIE:
>    word-wrap: normal | break-word
>    [wrap / no-wrap settings given with 'white-space']
> 
> Proposed A:
>    wrap-option: wrap | no-wrap | character-wrap | force-wrap 
> Proposed B:
>    text-wrap: wrap | nowrap | character-wrap
>    word-wrap: normal | break-word
> 
> Justification:
>    'soft-wrap' is misleading: to most people, it means "wrap without
>    inserting hard line breaks"
> 
>    'emergency' is weird and inaccurate (it wraps on regular breaks
>    when it's not an "emergency"); 'force-wrap' is much more
>    self-explanatory. (This value allows wrapping of very long words
>    words to prevent overflow.)
> 
> Compatibility:
> 
>   * The advantage of separating out word-wrap is that it cascades
>     independently. Since wrapping is traditionally set by the
>     'white-space' property, which currently has no force-wrap option,
>     this allows easy, current-ua-compatible retro-fitting of existing
>     content: set "word-wrap: break-word" on the root element, and any
>     time you set 'white-space' to allow wrapping, it will allow
>     force-wrapping in UAs that support it.
> 
>   * WinIE has already implemented things this way, and we can define
>     'wrap-option' as a shorthand that will be compatible with XSL.
> 
>   * If we take this route, the 'white-space' shorthand will 
> not be able
>     to set force-wrapping (because white-space and word-wrap will be
>     independent).
> 
>   * If we didn't have this backwards-compat situation, it 
> would certainly
>     be better not to split them up.
> 

<snap/>

See my previous note about how it would be incorrect to conflate line-break and word-break-cjk, and assorted other notes.

I'm wondering, however, whether it wouldn't be possible to conflate word-break-cjk and wrap-option.  Couldn't we just make wbcjk's keep-all and break-all values additional values for wrap-option? (perhaps rename them to keep-all-words and break-all-words).  Word-break-cjk's normal value would then be the default behaviour for wrap-option:wrap and wrap-option:emergency.

I think that the word-break-cjk:normal option (whether or not it is combined with wrap-option) should spell out more clearly that thai-like scripts' default behaviour of breaking at invisible word boundaries is included in the phrase "Keeps non-CJK scripts together..." (and I think that should read "Keeps words in non-CJK scripts together...").  This is another reason that I dislike the name word-break-cjk, since afaict it describes the default behaviour with the normal option for all scripts.  (Or have I misunderstood something?)

Wrt naming conventions:

Why not call soft-wrap simple-wrap - it is after all just a simple approach to wrapping - I think calling it character-wrap risks confusing people, since they will expect that this is what you are supposed to use for CJK text - this is not the case because of the absence of kinsoku/geumchik rules.

Rather than force-wrap for emergency, I'd suggest long-line-wrap.  Force-wrap to my mind sounded like an alternative name for soft-wrap.  Another possibility might be long-word-wrap, or wrap-all.


Hope that helps,
RI

Received on Friday, 15 October 2004 11:22:57 UTC