Re: [css3-text] Splitting CSS Text into Level 3 and Level 4

Also sprach Brad Kemper:

 > > Why not just:
 > > 
 > >  @text-transform latin-only-uppercase { convert: "a-z" to "A-Z"; }
 > > 
 > > It's shorter and we don't need to introduce another descriptor. (Which
 > > leaves us with only one descriptor, but that's ok)

 > You're right; I agree. I should look more closely at what I copy/paste. So together these should be:
 > 
 > @text-transform latin-only-uppercase { convert: "a-z" to "A-Z"; }
 > @text-transform latin-german-lowercase { convert: latin-only-uppercase, "ẞ" to "ß" }

Yes.

 > You could also convert ranges to a single character, if you wish:
 > 
 > @text-transform bulletize-numbers { convert: "0-9" to "•"; }

Neat.

 > If the number of items don't match, I would say:
 > 
 > • if the first list is shorter then ignore extra items in the second list

Yes. 

 > • if the first list is longer, then apply the last item of the
 > first list to all remaining items in the second list.

I can't parse that. Wouldn't it be:

  if the first list is longer, then apply the last item of the second
  list to all remaining items in the first list

 > Thus, the following could be useful:
 > 
 > @text-transform bulletize-latin-and-numbers { convert: "0-9 a-z A-Z" to "•"; }
 > 
 > But on these, extra junk is discarded:
 > 
 > @text-transform shift-numbers { convert: "0-9" to "! @ # $ % ^ & * ( ) _ + - = < > ? : \" { } |"

Yes.

 > (Note that I also escaped a quote mark in that example. We should
 > also be able to escape the space character, single quote, and
 > slash.)

The slash ('/') doesn't need escaping, but the backslash ('\') does.

And the dash ('-'), to avoid treating it as a range descriptor.

Should we allow "negative" ranges? As in:

  convert: z-a to "•";

Probably not. The presence of a "negative range" should probably lead
to discarding the whole statement:

  convert: "0-9 z-a A-Z" to "•"; }  /* no effect */
  convert: lowercase, "æ" to "Æ", "0-9 z-a A-Z" to "•"; }  /* no effect */

 > What about some sort of "not" indicator? So for instance:
 > 
 > @text-transform bulletize-special-characters { convert: not "0-9 a-z A-Z" to "!"; } 
 > /* for indicating problems with a new user id that has limited character support */

Interesting. Powerful. I'd say yes.

-h&kon
              Håkon Wium Lie                          CTO °þe®ª
howcome@opera.com                  http://people.opera.com/howcome

Received on Friday, 16 December 2011 18:28:50 UTC