<rdar://problem/11928576> SVG-as-image (constrained) intrinsic size calculation is...
authormitz@apple.com <mitz@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 21 Jul 2012 21:54:31 +0000 (21:54 +0000)
committermitz@apple.com <mitz@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 21 Jul 2012 21:54:31 +0000 (21:54 +0000)
commitd31ca836f7e8361654a5db4dd86bb2f5a8ebe3fc
tree588fded06d822b2f05673af78f2760626caae7c9
parent1edb61266541d74932cfa214003c1b6443b740bf
<rdar://problem/11928576> SVG-as-image (constrained) intrinsic size calculation is wrong in vertical writing modes
https://bugs.webkit.org/show_bug.cgi?id=91918

Reviewed by Anders Carlsson.

Source/WebCore:

Test: svg/as-image/svg-intrinsic-size-rectangular-vertical.html

* rendering/RenderReplaced.cpp:
(WebCore::RenderReplaced::computeAspectRatioInformationForRenderBox): When there is a content
renderer, it returns a physical intrinsic size and aspect ratio. The code was already
accounting for this by taking the reciprocal of the aspect ratio in the vertical case. Made
it also transpose the size itself, turning it from physical to logical. Moved this code
after setting m_intrinsicSize, since that member variable is always physical.

LayoutTests:

* svg/as-image/svg-intrinsic-size-rectangular-vertical-expected.html: Added.
* svg/as-image/svg-intrinsic-size-rectangular-vertical.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@123294 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/svg/as-image/svg-intrinsic-size-rectangular-vertical-expected.html [new file with mode: 0644]
LayoutTests/svg/as-image/svg-intrinsic-size-rectangular-vertical.html [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/rendering/RenderReplaced.cpp