commit | eb69d642bf4c5a3e568ac916576156cda27bfe7d | [log] [tgz] |
---|---|---|
author | davve@opera.com <davve@opera.com@bbb929c8-8fbe-4397-9dbb-9b2b20218538> | Mon Jun 09 09:31:21 2014 |
committer | davve@opera.com <davve@opera.com@bbb929c8-8fbe-4397-9dbb-9b2b20218538> | Mon Jun 09 09:31:21 2014 |
tree | 906dded74b5e14385c8fc7faf30ad18d49da52f5 | |
parent | 1f2c5b563ba10649448fbf6ca6e1bc2d88202a9f [diff] |
Teach SVGImage::containerSize() to deduce intrinsic values When an SVG has either intrinsic width or height but not both, and a intrinsic ratio, the missing intrinsic width or height can be calculated. Doing so enables us to return correct intrinsic width and height for SVG images in more cases when the image has no renderer. Also, this patch removes the unspecified use of the viewBox attribute as the source of intrinsic size. A small number of tests depended on this and has been updated. The reasoning to make this change is because we don't use the viewBox for intrinsic size in any other context than SVGImage. And we only use it until the renderer has a containerSize() anyway. http://www.whatwg.org/specs/web-apps/current-work/multipage/edits.html#dom-img-width http://www.whatwg.org/specs/web-apps/current-work/multipage/edits.html#dom-img-height BUG=376895 Review URL: https://codereview.chromium.org/308643002 git-svn-id: svn://svn.chromium.org/blink/trunk@175784 bbb929c8-8fbe-4397-9dbb-9b2b20218538