Re: WebIDL-compatible syntax compromise

On 18/04/14 20:54, Justin Uberti wrote:
Been thinking about this a while. Overall, I understand the goals here but it still seems complicated to express the common use case of "please give me HD, but definitely no less than VGA". As I understand it, this would be done via:

  {
    require: ["width", "height"],
    width: {min: 640},
    height: {min: 480},
    prefer: [{width: 1280, height: 720}]
  }

which is OK, but I think this would be more understandable as

  {
    require: { width: {min: 640}, height: {min: 480} },
    prefer: [{width: 1280, height: 720}]
  }
This is perhaps a little easier to understand, but the app designer _can_ express "please give me HD, but definitely no less than VGA" with the syntax compromise developed by Dan, Jan-Ivar and Jim. I think that, along with implementers implementing support for it, is the most important thing. Besides, we've also said we'll consider "ideal" again once this part settles, which can make it more straightforward.

which alas, seems like the syntax we already have, e.g.

 {
    mandatory: { width: {min: 640}, height: {min: 480} },
    optional: [{width: 1280, height: 720}]
  }

What am I missing here?


On Thu, Apr 3, 2014 at 5:09 AM, Steev James <steev.a.james@gmail.com<mailto:steev.a.james@gmail.com>> wrote:
"Preferred" seems to be good instead of advanced.


On Thu, Apr 3, 2014 at 1:10 PM, Dominique Hazael-Massieux <dom@w3.org<mailto:dom@w3.org>> wrote:
On mar., 2014-04-01 at 21:17 -0400, Dan Burnett wrote:
> At the teleconference last week we were tasked with finding a way to
> adjust the current constraint syntax in the specification, without
> loss of expressivity, into a syntax that was WebIDL-compatible.  We
> may have done one better.
>
> We have found a workable compromise.

Thanks guys, this look quite good!

My only comment is similar to one that others have made: I think
"advanced" is not very descriptive; I'm thinking maybe
"preferredProfiles" or something like that might be clearer. But I don't
feel strongly at all about it, and I'm happy to leave this to the
editors discretion as far as I am concerned.

Dom

Received on Saturday, 19 April 2014 13:12:26 UTC