Subject: [Ltru] xml:lang syntax

From: Peter Constable <[email-masked]>
Date: Wed, 7 May 2008 21:10:42 -0700

I'm trying to understand what XML does or does not allow as attribute values for xml:lang. The text of XML 1.1 (2nd Edn), section 2.12 states:

"The values of the attribute are language identifiers as defined by [IETF RFC 3066]<http://www.w3.org/TR/2006/REC-xml11-20060816/#RFC1766>, Tags for the Identification of Languages, or its successor; in addition, the empty string may be specified."

It's not completely clear to me from this if xml:lang="en,fr" is acceptable. I think a strict reading of 2.12 indicates that that is not well-formed: "en,fr" is not a language identifier defined by RFC 3066 or successors.

Peter
_______________________________________________
Ltru mailing list
[email-masked]
https://www.ietf.org/mailman/listinfo/ltru

---

From: John Cowan <[email-masked]>
Date: Thu, 8 May 2008 00:16:41 -0400

Peter Constable scripsit:

> "The values of the attribute are language identifiers as defined by
> [IETF RFC 3066]<http://www.w3.org/TR/2006/REC-xml11-20060816/#RFC1766>,
> Tags for the Identification of Languages, or its successor; in addition,
> the empty string may be specified."

That is meant to mean that the value of each xml:lang attribute is a
single language tag.

> It's not completely clear to me from this if xml:lang="en,fr"
> is acceptable.

It isn't.

-- 
John Cowan  [email-masked]   ccil.org/~cowan
Dievas dave dantis; Dievas duos duonos          --Lithuanian proverb
Deus dedit dentes; deus dabit panem             --Latin version thereof
Deity donated dentition;
  deity'll donate doughnuts                     --English version by Muke Tever
God gave gums; God'll give granary              --Version by Mat McVeagh
_______________________________________________
Ltru mailing list
[email-masked]
https://www.ietf.org/mailman/listinfo/ltru

---

From: Leif Halvard Silli <[email-masked]>
Date: Thu, 08 May 2008 07:50:09 +0200

> That is meant to mean that the value of each xml:lang attribute is a

In the W3 L18N list I aired - without response [*] - the option of 
having a single language tag that covered several languages. Something 
like xml:lang="mul-en-fr", to say that it was multilingual English and 
French. It ought not no be necessary to be very spesific about script 
and/or geography etc in such a tag. It would at least have to work a bit 
differently from th eother tags.

[*] (Though I got support from some for the very idea about specifying 
several languages for one element.)

> > It's not completely clear to me from this if xml:lang="en,fr"

This means that we can say xml:lang="mul" and encompass all the 
langugeas of the world. But not any two or more languages. With 
xml:lang="mul-en-fr" one coud be more spesific.
-- 
leif halvard sillli

---

From: Peter Constable <[email-masked]>
Date: Thu, 8 May 2008 00:45:57 -0700

> From: Leif Halvard Silli [mailto:[email-masked]]

> xml:lang="mul-en-fr" one coud be more spesific.

Except that, as I suspected, it's not acceptable XML.

Peter

---

From: Leif Halvard Silli <[email-masked]>
Date: Thu, 08 May 2008 11:07:06 +0200

Andrew Cunningham 2008-05-08 10.04:
> 2008/5/8 Leif Halvard Silli <[email-masked]>:
>

> Doing something like xml:lang="mul-en-fr" would not be a good way to
> go. The xml:lang attribute would indicate the language of the contents
> of an element and should be a single value. Adding multiple vlaues
> would affect inheritance of language values. It would effect
> processing data and displaying data.
>   

Rethinking: Perhaps it is not advicable on the xml:lang tag, which only 
is inside the root element - if I remember. But the very thing, to be 
able to specify mul-en-fr on other elements than the root element, seems 
meaningful to me.

Does that sound better?

But otherwise, even for xml:lang, there is no principle diff between 
xml:lang="mul" - which I guess isn't forbidded - and xml:lang="mul-en-fr".
-- 
leif halvard silli
_______________________________________________
Ltru mailing list
[email-masked]
https://www.ietf.org/mailman/listinfo/ltru

---

From: Leif Halvard Silli <[email-masked]>
Date: Thu, 08 May 2008 10:34:55 +0200

Andrew Cunningham 2008-05-08 10.04:
> Hi all,
> There is a need to be able specify the intended audience of a
> document, in HTML terms there is covered by the HTTP Header and
> metadata in the document, which could contain multiple values. I'll
> leave aside the fact that many user agents don't do anything
> meaningful with that data, but it is possible to add the data.
>
> At any one time you would not be able to identify the language of text
> being processed from the xml:lang attribute.
>   

By using lang="mul" I would say that that content was multlingual. That 
would be useful, e.g. via CSS. And I can't see it would break xml:lang, 
as you also mentioned. Adding "mul-fr-en" is just a more spesific tagging.
-- 
leif halvard

---

From: "Andrew Cunningham" <[email-masked]>
Date: Thu, 8 May 2008 18:04:59 +1000

Hi all,

If you were defining a schema or DTD you could create an attribute to
identify audience or document language(s) that could contain multiple
values. There is no need to break xml:lang.

Andrew

-- 
Andrew Cunningham
Vicnet Research and Development Coordinator
State Library of Victoria
Australia

[email-masked]
[email-masked]

---

From: John Cowan <[email-masked]>
Date: Thu, 8 May 2008 12:14:09 -0400

> able to specify mul-en-fr on other elements than the root element, seems 

No, it may be used on any element, and is scoped to the content of that
element, <span xml:lang="fr">par exemple</span>, thus.

> xml:lang="mul" - which I guess isn't forbidded - and xml:lang="mul-en-fr".

Except that "mul" is a valid language tag and "mul-en-fr" isn't even well-formed.

-- 
John Cowan    [email-masked]    http://ccil.org/~cowan
   There was an old man                Said with a laugh, "I
     From Peru, whose lim'ricks all      Cut them in half, the pay is
       Look'd like haiku.  He              Much better for two."
                                             --Emmet O'Brien
_______________________________________________
Ltru mailing list
[email-masked]
https://www.ietf.org/mailman/listinfo/ltru

---

From: Peter Constable <[email-masked]>
Date: Thu, 8 May 2008 09:37:06 -0700

Trying to solve the kinds of problems xml:lang="mul-en-fr" is trying to solve has nothing to do, IMO, with the issues we're trying to sort out to complete 4646bis, and belongs entirely on the side of the consuming application of 4646bis, not in 4646 itself. I think we could end that discussion.

My $.02.

Peter

> -----Original Message-----
> From: [email-masked] [mailto:[email-masked]] On Behalf Of
> Leif Halvard Silli
> Sent: Thursday, May 08, 2008 2:07 AM
> To: Andrew Cunningham
> Cc: LTRU Working Group
> Subject: Re: [Ltru] xml:lang syntax
>

---

From: "Mark Davis" <[email-masked]>
Date: Thu, 8 May 2008 09:59:35 -0700

Agreed. The one thing we might do for the text is make it clear that we
recommend the use of language priority tests, both for queries and tagging,
wherever possible.

On Thu, May 8, 2008 at 9:37 AM, Peter Constable <[email-masked]>
wrote:

> Trying to solve the kinds of problems xml:lang="mul-en-fr" is trying to
> solve has nothing to do, IMO, with the issues we're trying to sort out to
> complete 4646bis, and belongs entirely on the side of the consuming
> application of 4646bis, not in 4646 itself. I think we could end that
> discussion.
>
>
> My $.02.
>
> Peter
>
>
>

-- 
Mark

---

From: Shawn Steele <[email-masked]>
Date: Thu, 8 May 2008 10:23:36 -0700

Ø  Agreed. The one thing we might do for the text is make it clear that we recommend the use of language priority tests, both for queries and tagging, wherever possible.

I would like to see text that  recommends language priority lists (when appropriate) on both sides.  It doesn’t have to be as involved as my proposed text was, but I’d like to see something.

Peter’s made me uncertain if that is sufficient for the Chinese case since existing protocols don’t allow lists in some interesting cases.

-          Shawn

---

From: Leif Halvard Silli <[email-masked]>
Date: Thu, 08 May 2008 19:50:01 +0200

John Cowan 2008-05-08 18.14:
> No, it may be used on any element, [...]
>   

Of course. Sorry.

> Except that "mul" is a valid language tag and "mul-en-fr" isn't even well-formed.

Of course. But the interesting thing is if it can be set up in 
well-formed way.
-- 
leif halvard silli

---

From: Leif Halvard Silli <[email-masked]>
Date: Thu, 08 May 2008 20:06:28 +0200

> Except that, as I suspected, it's not acceptable XML.

If it is not acceptable XML, then it is because it is not an acceptable 
language tag - as John pointed out.
-- 
leif halvard silli
_______________________________________________
Ltru mailing list
[email-masked]
https://www.ietf.org/mailman/listinfo/ltru

---

From: Leif Halvard Silli <[email-masked]>
Date: Thu, 08 May 2008 20:14:55 +0200

Peter Constable 2008-05-08 18.37:
> xml:lang="mul-en-fr"  [...] I think we could end that discussion.
>   

I take note.

---

From: Leif Halvard Silli <[email-masked]>
Date: Thu, 08 May 2008 20:17:31 +0200

> I would like to see text that  recommends language priority lists (when appropriate) on both sides.  It doesn’t have to be as involved as my proposed text was, but I’d like to see something.

I agree with this. And I did not find your text involved.
-- 
leif halvard silli
_______________________________________________
Ltru mailing list
[email-masked]
https://www.ietf.org/mailman/listinfo/ltru