Re: Lack Of Definition Of A Valid Ratio (part of detailed review of common microsyntaxes)

Robert Burns writes:

> Also I think step 6 of the algorithm:
> 
> "If there are still further characters in the string, and the next  
> character in the string is a valid denominator punctuation character,  
> set denominator to that character."
> 
> should be changed to something like:
> 
> "If there are still further characters in the string, and the next  
> character in the string is a valid denominator punctuation character,  
> set denominator to the value associated with that character from  
> table [tableref]"

Note the doc for <meter>'s 'The maximum value' says:

  if the result was one number but it had an associated denominator
  punctuation character, then the maximum value is the value associated
  with that denominator punctuation character; and finally, if there
  were two numbers parsed out of the textContent, then the maximum is
  the higher of those two numbers.

So the translation from denominator to value is taking place at that
place rather than in the defintion of ratio itself.

This enables <meter> to know what any denominator is, so it could use
that in its rendering.  For example a talking browser might say a ratio
of 75/100 as "seventy-five out of a hundred", but 75% as "seventy-five
percent".  If both ratios are parsed as the two numbers 75, 100 then it
would not be able to make this distinction.

Smylers

Received on Wednesday, 11 July 2007 14:24:46 UTC