- From: fantasai <fantasai.lists@inkedblade.net>
- Date: Wed, 17 Jun 2015 06:32:52 -0400
- To: Dean Jackson <dino@apple.com>, Patrick Dark <www-style.at.w3.org@patrick.dark.name>
- CC: "www-style@w3.org" <www-style@w3.org>, www-svg <www-svg@w3.org>
On 06/14/2015 04:31 AM, Dean Jackson wrote: > >> On 14 Jun 2015, at 9:09 am, Patrick Dark <www-style.at.w3.org@patrick.dark.name >> <mailto:www-style.at.w3.org@patrick.dark.name>> wrote: >> >> >> On 5/28/2015 8:51 PM, Dean Jackson wrote: >>> I'm not sure if this is a UI spec thing, or borders, or something that's just fallen through the cracks. WebKit recently >>> landed a change to make border-image with an SVG resource, that has no intrinsic size, behave like Firefox. >>> >>> https://bugs.webkit.org/show_bug.cgi?id=139405 >>> >>> Example/Test is here: >>> http://trac.webkit.org/export/184972/trunk/LayoutTests/fast/borders/border-image-fill-no-intrinsic-size.html >>> >>> Chrome had the same behaviour as WebKit did, before the change. I haven't tested on IE/Edge (sorry... I really need to set >>> up a login). >>> >>> It's not completely clear what the best thing to do in this case is, but we think the Firefox behaviour was better. Is this >>> specified anywhere? We'd really like to encourage people to not put an intrinsic size in their SVG. >>> >> >> Your test document is missing tests with intrinsic dimensions specified via the SVG element's |viewBox| attribute: >> |viewBox="0,0 100,100"|. > > The viewBox cannot imply any intrinsic dimensions. If it did, an SVG map that was using mm for units and displaying the entire > world with an appropriate viewBox would be stupidly big. > > It *might* be able to imply intrinsic aspect ratio. I'm pretty sure the viewBox implies an intrinsic aspect ratio. The SVGWG can correct me if I'm wrong, but I think this is what happens: [none] -> no intrinsic size viewBox -> intrinsic aspect ratio width -> intrinsic width height -> intrinsic height only width+height -> intrinsic width, intrinsic height, and (derived) intrinsic aspect ratio width+viewBox -> intrinsic width, (derived) intrinsic height, intrinsic aspect ratio height+veiwBox -> (derived) intrinsic width, intrinsic height, intrinsic aspect ratio width+height+viewbox -> intrinsic width, intrinsic height, intrinsic aspect ratio I'm not really sure what happens when the aspect ratio conflicts with the width/height ratio, but in any case, all of this should be specified clearly by the SVG spec, and if it's not, it needs to be specified there. The CSS specs (Images and Backgrounds) are already very explicit about what happens with all combinations of intrinsic {aspect ratio, width, height}. ~fantasai
Received on Wednesday, 17 June 2015 10:35:24 UTC