W3C home > Mailing lists > Public > www-html@w3.org > August 2006

Re: Number, Date, Time, Quantity

From: Jukka K. Korpela <jkorpela@cs.tut.fi>
Date: Wed, 30 Aug 2006 19:12:56 +0300 (EEST)
To: www-html@w3.org
Message-ID: <Pine.GSO.4.64.0608301905080.14525@mustatilhi.cs.tut.fi>

On Wed, 30 Aug 2006, Hendry, Alan wrote:

> If there was a tag like <number>1,234.56</number>
> it could be displayed as 1.234,56 based upon the users settings
> (regional options in Windows)

It could, but why? The user settings relate to the user's preferred 
language and locale. Why should they be applied to the rendering of a 
document in another language? That would just create confusion.
If I saw a document in English with "1,005" in it, I would expect that to 
mean one thousand five, but your idea would make <number>1.005</number> 
appear that way to me!

> further it could be read as "one thousand two hundred ..." by a screen
> reader

That's good point. Speech-based user agents have difficulties with digit 
strings. They typically have settings for reading them as numbers or by 
digits, but this is not optimal since this should depend on the context 
and meaning of the digit sequence.

Another point: <number>1.2</number> (on a page in English) could be 
translated as <number>1,2</number> (in most languages) by automatic 
translation software. The problem, however, is that we would need markup 
for things like 1.2 that should _not_ be treated as numbers, e.g. as a 
section number or a version number. Some automatic translators have turned 
e.g. "HTML 3.2" into "HTML 3,2" since they assumed "3.2" to be a number 
with a decimal point.

> If there was a tag like <shortdate>31/12/2006</shortdate>
> it could be displayed as 12-31-06 based on the users settings

Similar considerations apply. Besides, 31/12/2006 follows a local 
convention already, instead being in a neutral international notation 

> If there was a tag like <quantity unit=km>1.6</quantity>
> then it could be displayed as 1 MILE

I'm afraid it might, so you would also lose accuracy.

Jukka "Yucca" Korpela, http://www.cs.tut.fi/~jkorpela/
Received on Wednesday, 30 August 2006 16:13:02 UTC

This archive was generated by hypermail 2.4.0 : Thursday, 30 April 2020 16:21:00 UTC