Re: [SVG2] Clock-value syntax

On Tue, 24 Jun 2014 01:48:18 +0200, Tab Atkins Jr. <jackalmage@gmail.com>  
wrote:

> On Mon, Jun 23, 2014 at 4:38 PM, Brian Birtles <bbirtles@mozilla.com>  
> wrote:
>> On 2014/06/23 20:56, Erik Dahlström wrote:
>>>
>>> Hi,
>>>
>>> posting to mention a small issue that came up in a user forum:
>>>
>>> The Clock-value syntax [1] used e.g for the begin and end attributes
>>> doesn't quite match the way other numerical values (<number>) are
>>> parsed[2].
>>
>>
>> How about extending extend CSS's <time> production to include "h" and  
>> "min"
>> and using that?[1]
>
> I am okay with doing this.  I suspect it would be uncontroversial if
> there were use-cases, which this is.
>
>> Just as I'm sure it's confusing that you can write:
>>
>>          animation-duration: .2s
>> but not: <animate dur=".2s">
>>
>> It's probably also confusing that you can write:
>>
>>          <animate dur="2min">
>> but not: animation-duration: 2min
>
> Agreed, confusing and bad. Harmonizing would be great.

Sounds good to me.

>> As Robert points out, though, we'd need to work out how to handle  
>> negative
>> values.
>>
>> begin/end actually allow you to write, begin="- 2s" with a space in the
>> middle. I'm pretty sure <number> doesn't allow that.
>
> Yes, it doesn't allow that.  Number signs must be adjacent to the digits.

That is true.

>> dur doesn't allow negative values (they produce a parse error in  
>> Firefox). I
>> guess, like CSS,[2] we could say in prose that negative <time> values  
>> are
>> invalid in those cases and continue reporting parse errors.
>
> Sounds reasonable to me.

Right, shouldn't be a problem. Nit: it's not just negative values, 0 is  
also disallowed in 'dur'.


-- 
Erik Dahlstrom, Web Technology Developer, Opera Software
Co-Chair, W3C SVG Working Group

Received on Tuesday, 24 June 2014 15:00:57 UTC