[svgwg] Issue: Define all cases for intrinsic ratio marked as SVG 2

nikosandronikos has just labeled an issue for 
https://github.com/w3c/svgwg as "SVG 2":

== Define all cases for intrinsic ratio ==
Currently in the spec, we have this issue 
https://www.w3.org/TR/2015/WD-SVG2-20150915/coords.html#issue30

This section maybe isn't as well written as it could be, but I think 
it's complete in terms of describing all it needs to describe. But I 
would like a second opinion.

The constraints are:
- width and height are presentation attributes.
- the default value for width and height is `auto` and `auto` is 
defined to be 100%
- this means that width and height are never unspecified. The default 
is to be 100% of the containing block.
- If no viewBox exists, the extra transformation defined by the 
viewBox is simply omitted. Additionally ,preserveAspectRatio is 
ignored if no viewBox is given.

These constraints mean that the possible combinations are:

|width|height|viewbox|intrinsic ratio|
|-----|------|-------|---------------|
|length|length|VB.w x VB.h|width / height|
|length|percentage|VB.w x VB.h|VB.w / VB.h|
|percentage|length|VB.w x VB.h|VB.w / VB.h|
|percentage|percentage|VB.w x VB.h|VB.w / VB.h|
|length|length|unspecified|width / height|
|length|percentage|unspecified|undefined|
|percentage|length|unspecified|undefined|
|percentage|percentage|unspecified|undefined|

Which are all covered by the current prose.

So I'm tempted to just do some general tidy up of that section and 
close the issue. Does anyone who knows more about this than me 
disagree?

See https://github.com/w3c/svgwg/issues/197

Received on Monday, 11 July 2016 03:41:22 UTC