I'm following an interesting discussion on www-style about new ideas
for new pseudo-elements in CSS3. Latest entries concern the ::first-
word pseudo-element. I quote the most relevant ones:
----------------------------------------------------------------------------------------------------------------------------------------------------------
Pierre Bertet wrote:
But the ::first-letter already do this, defining a "letter", wich is
not very clear too. To clarify this, the CSS3 Selectors spec refers to
the Unicode Standard Annex #29 [1].
This document seems very complex to me, but it also contains a “Word
Boundaries” section, which seems to defines exactly that.
So my questions are:
This section could it not be used to clarify what a “word” is?
The extensive caveats in the notes to that section of TUS Annex #29
would need to be taken into account. Word boundary identification
needs to be tailored for many languages, and the basic Unicode
mechanism only aims to provide 'as workable a default as possible'.
Words -- and syllables, which present similar issues for selecting
appropriate text elements for styling -- are units of spoken language
that may or may not be easily isolated as units in written language,
depending on particular writing systems as applied to particular
languages. In some systems, e.g. Thai, word selection is only possible
with dictionary support.
------------------------------------------------------------------------------------------------------------------------------------------------
So the point is that it doesn't exist a clear definition of word (in
its textual representation, but, ouch, also in linguistics) and for
that reason this proposal has been rejected. But there are other
interesting ideas of this sort, such as:
1. nth-line()
Pseudo-class. It should select the nth-line of a block. But is
there a definition of line that could be accepted?
2. nth-word()
Pseudo-class. See the objections above.
The point is that we all have good ideas and hints on CSS, but the sad
truth is that on www-style they don't pass the first reader comments.
Anyway, I encourage you on following these discussions because there's
always something new to learn.
Good night, (my time, Rome CET)
G. :-)
http://www.css-zibaldone.com
http://www.css-zibaldone.com/test/ (English)
http://www.css-zibaldone.com/articles/ (English)
http://onwebdev.blogspot.com/ (English)
______________________________________________________________________
css-discuss [[email protected]]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/