Re: [Bug 26526] Fix aspect ratio constraint

On 08/15/2014 10:00 AM, Silvia Pfeiffer wrote:
>
> I don't believe this is a valid argument when it makes it impossible 
> for authors to write readable code: 
> http://www.w3.org/TR/html-design-principles/#priority-of-constituencies
>

When something's a number in Javascript, it's perfectly legal to write 
an expression like 16/9 in that space.

Your other alternatives - { num: 16, den: 9 } and "16/9" - are, to me, 
more complex and less readable - the author has to remember that while 
he thinks of it as a number, he has to remember that there is a special 
syntax that is only used for expressing numbers in this particular place.

Specifying an epsilon allows the author to write the number in most 
fashions he's used to, and have the result of the comparision be the same.

I believe the epsilon solution is the easiest one for authors.

> Best Regards,
> Silvia.
>
> On 15 Aug 2014 16:52, "Harald Alvestrand" <harald@alvestrand.no 
> <mailto:harald@alvestrand.no>> wrote:
>
>     On 08/15/2014 03:38 AM, Silvia Pfeiffer wrote:
>     > On Fri, Aug 15, 2014 at 10:27 AM, Martin Thomson
>     > <martin.thomson@gmail.com <mailto:martin.thomson@gmail.com>> wrote:
>     >> On 14 August 2014 16:47, Silvia Pfeiffer
>     <silviapfeiffer1@gmail.com <mailto:silviapfeiffer1@gmail.com>> wrote:
>     >>> Out of curiosity, what's the advantage is being inexact when
>     we can easily
>     >>> be exact?
>     >> If you have a proposal, please share.
>     > See earlier in the thread, I see either two integers or a string
>     being
>     > better for specifying a rational number. As stated, though, I am not
>     > fussed. I just want to know why there are very strong voices for a
>     > single float value for "aspect" rather than one of the other
>     options.
>
>     Because all other values in the constraints system are either strings
>     that match exactly or not at all or numbers where it makes sense to
>     compute distances.
>
>     Introducing a third data type (string that has to be processed in some
>     way, or pair-of-numbers that still has to be comparable for distance)
>     complicates the overall system, without bringing a corresponding
>     benefit
>     (as far as I can see).
>
>

Received on Friday, 15 August 2014 08:08:56 UTC