W3C home > Mailing lists > Public > www-style@w3.org > October 2003

Re: CSS2.1 :lang

From: Tex Texin <tex@i18nguy.com>
Date: Thu, 16 Oct 2003 19:58:59 -0400
Message-ID: <3F8F30C3.1F802EB6@i18nguy.com>
To: ishida@w3.org
Cc: 'Bert Bos' <bert@w3.org>, www-style@w3.org, 'W3c I18n Group' <w3c-i18n-ig@w3.org>

Richard,
The language code is also defined earlier. If the matching algorithm has no
dependencies on the values of the language and country etc codes, then by
defining it independently of the RFC, we don't need to keep revising this
section when the  content of the language code is revised. For example, if it
is revised to include script in the name.

It makes the specification more precise as well, as referencing these other
documents leaves it to the imagination as to what the correct behavior is when
presented invalid values, etc.

The baby is much safer if it is not left in the bathtub at all.
;-)
tex


Richard Ishida wrote:
> 
> > > For the purposes of matching, I wonder if it makes sense to
> > reference
> > > the RFCs at all. Isn't it really string matching based on strings
> > > formatted with hyphen separators? Does any software verify that the
> > > language tag contains appropriately registered codes or uses ISO
> > > codes? Should it be an error, or perhaps the rule ignored, if a CSS
> > > document specifies  :lang(k9) since k9 is not an offical
> > language code
> > > or a properly formatted private code.
> >
> > I like that suggestion: it removes a dependency.
> >
> > The definition of the "|=" operator is already generic. It
> > only requires a UA to split a string value at every "-" and
> > doesn't require the string to be a valid language. The
> > ':lang()' refers to that definition and could be made generic
> > as well, e.g.:
> >
> > Current text in 5.11.4:
> >
> >     The pseudo-class ':lang(C)' matches if the element is in language
> >     C. Here C is a language code as specified in HTML 4.0 [HTML40] and
> >     RFC 1766 [RFC1766]. It is matched the same way as for the '|='
> >     operator.
> >
> > Proposed:
> >
> >     The pseudo-class ':lang(C)' matches if the element is in language
> >     C. CSS doesn't define what are valid language names and the string
> >     C doesn't have to be a valid language name in the source document.
> >     It is matched the same way as for the '|=' operator.
> 
> I disagree with this proposed para.  I think you are throwing out the
> baby with the bath water.
> 
> I see the value of referring to RFC3066 is to ensure maximum
> standardisation/interoperability in the way language codes are used.
> For example, 3066 requires the use of 2-letter codes rather than
> 3-letter codes wherever they exist.  This is important advice for
> interoperability. 3066 also says that you should use ISO codes rather
> than some arbitrary label where it exists. Etc.
> 
> I think the original text was defining how one should label languages in
> CSS, not just how the matching should work.  And I think it is important
> to retain the former, though the text could certainly be reworded so as
> to separate the two ideas, remove the HTML reference and refer to
> RFC3066.
> 
> RI

-- 
-------------------------------------------------------------
Tex Texin   cell: +1 781 789 1898   mailto:Tex@XenCraft.com
Xen Master                          http://www.i18nGuy.com
                         
XenCraft		            http://www.XenCraft.com
Making e-Business Work Around the World
-------------------------------------------------------------
Received on Thursday, 16 October 2003 20:00:11 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:54:24 GMT