[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
commit-queue at webkit.org
commit-queue at webkit.org
Wed Dec 22 15:40:52 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit 94a6cbf04b04a1af898d44800dc4d4c679615131
Author: commit-queue at webkit.org <commit-queue at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Wed Nov 10 09:04:09 2010 +0000
2010-11-10 Shane Stephens <shanestephens at google.com>
Reviewed by Dirk Schulze.
SVGTextElement supplemental transforms pre-multiplied but should be
post-multiplied in animatedLocalTransform
https://bugs.webkit.org/show_bug.cgi?id=48215
* svg/animations/animate-text-nested-transforms-expected.txt: Added.
* svg/animations/animate-text-nested-transforms.svg: Added.
2010-11-10 Shane Stephens <shanestephens at google.com>
Reviewed by Dirk Schulze.
SVGTextElement supplemental transforms pre-multiplied but should be
post-multiplied in animatedLocalTransform
https://bugs.webkit.org/show_bug.cgi?id=48215
Test: svg/animations/animate-text-nested-transforms.svg
* svg/SVGTextElement.cpp:
(WebCore::SVGTextElement::animatedLocalTransform):
Switched order of multiplication. Note that due to a bug in
AffineTransform's operator* implementation the order of arguments is
reversed (see http://bugs.webkit.org/show_bug.cgi?id=48031).
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@71726 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index 6a7b3e9..0f1e6cf 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,3 +1,14 @@
+2010-11-10 Shane Stephens <shanestephens at google.com>
+
+ Reviewed by Dirk Schulze.
+
+ SVGTextElement supplemental transforms pre-multiplied but should be
+ post-multiplied in animatedLocalTransform
+ https://bugs.webkit.org/show_bug.cgi?id=48215
+
+ * svg/animations/animate-text-nested-transforms-expected.txt: Added.
+ * svg/animations/animate-text-nested-transforms.svg: Added.
+
2010-11-10 Fumitoshi Ukai <ukai at chromium.org>
Unreviewed, updating Chromium expectations
diff --git a/LayoutTests/svg/animations/animate-text-nested-transforms-expected.txt b/LayoutTests/svg/animations/animate-text-nested-transforms-expected.txt
new file mode 100644
index 0000000..b5c89a4
--- /dev/null
+++ b/LayoutTests/svg/animations/animate-text-nested-transforms-expected.txt
@@ -0,0 +1,20 @@
+Test nested text transforms with animateMotion
+
+This is some text.
+test to determine whether auto-rotate animateMotion path animations pre-muliply or post-multiply animation transform matrix
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+
+
+
+
+PASS rootSVGElement.getBBox().x is almost 390 (within 20)
+PASS rootSVGElement.getBBox().y is almost 140 (within 20)
+PASS rootSVGElement.getBBox().x is almost 700 (within 20)
+PASS rootSVGElement.getBBox().y is almost 270 (within 20)
+PASS successfullyParsed is true
+
+TEST COMPLETE
+
diff --git a/LayoutTests/svg/animations/animate-text-nested-transforms.html b/LayoutTests/svg/animations/animate-text-nested-transforms.html
new file mode 100644
index 0000000..1ce9109
--- /dev/null
+++ b/LayoutTests/svg/animations/animate-text-nested-transforms.html
@@ -0,0 +1,15 @@
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
+<html>
+ <head>
+ <link rel="stylesheet" href="../../fast/js/resources/js-test-style.css">
+ <script src="../../fast/js/resources/js-test-pre.js"></script>
+ <script src="../dynamic-updates/resources/SVGTestCase.js"></script>
+ <script src="resources/SVGAnimationTestCase.js"></script>
+ </head>
+ <body>
+ <h1>Test nested text transforms with animateMotion</h1>
+ <p id="description"/>
+ <div id="console"/>
+ <script src="script-tests/animate-text-nested-transforms.js"></script>
+ </body>
+</html>
diff --git a/LayoutTests/svg/animations/script-tests/animate-text-nested-transforms.js b/LayoutTests/svg/animations/script-tests/animate-text-nested-transforms.js
new file mode 100644
index 0000000..beb1aa9
--- /dev/null
+++ b/LayoutTests/svg/animations/script-tests/animate-text-nested-transforms.js
@@ -0,0 +1,51 @@
+description("test to determine whether auto-rotate animateMotion path animations pre-muliply or post-multiply animation transform matrix");
+createSVGTestCase();
+
+rootSVGElement.setAttribute("width", 800)
+
+var text = createSVGElement("text")
+text.setAttribute("transform", "translate(300, 30)")
+text.textContent = "This is some text."
+text.setAttribute("onclick", "executeTest()")
+
+var animateMotion = createSVGElement("animateMotion")
+animateMotion.setAttribute("id", "animation")
+animateMotion.setAttribute("dur", "1s")
+animateMotion.setAttribute("repeatCount", "1")
+animateMotion.setAttribute("rotate", "auto")
+animateMotion.setAttribute("path", "M 100,250 C 100,50 400,50 400,250")
+animateMotion.setAttribute("begin", "click")
+text.appendChild(animateMotion)
+rootSVGElement.appendChild(text)
+
+function passIfCloseEnough(name, value, error) {
+ passed = isCloseEnough(eval(name), value, error);
+ if (passed) {
+ testPassed(name + " is almost " + value + " (within " + error + ")");
+ } else {
+ testFailed(name + " is " + eval(name) + " but should be within " + error + " of " + value);
+ }
+}
+
+function startSample() {
+ passIfCloseEnough("rootSVGElement.getBBox().x", 390, 20);
+ passIfCloseEnough("rootSVGElement.getBBox().y", 140, 20);
+}
+
+function endSample() {
+ passIfCloseEnough("rootSVGElement.getBBox().x", 700, 20);
+ passIfCloseEnough("rootSVGElement.getBBox().y", 270, 20);
+}
+
+function executeTest() {
+ const expectedValues = [
+ ["animation", 0.1, "text", startSample],
+ ["animation", 1.0, "text", endSample]
+ ];
+
+ runAnimationTest(expectedValues);
+}
+
+window.setTimeout("triggerUpdate(310, 30)", 0);
+var successfullyParsed = true;
+
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 2641446..c8dbeb0 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,20 @@
+2010-11-10 Shane Stephens <shanestephens at google.com>
+
+ Reviewed by Dirk Schulze.
+
+ SVGTextElement supplemental transforms pre-multiplied but should be
+ post-multiplied in animatedLocalTransform
+ https://bugs.webkit.org/show_bug.cgi?id=48215
+
+ Test: svg/animations/animate-text-nested-transforms.svg
+
+ * svg/SVGTextElement.cpp:
+ (WebCore::SVGTextElement::animatedLocalTransform):
+
+ Switched order of multiplication. Note that due to a bug in
+ AffineTransform's operator* implementation the order of arguments is
+ reversed (see http://bugs.webkit.org/show_bug.cgi?id=48031).
+
2010-11-09 Abhishek Arya <inferno at chromium.org>
Reviewed by Dan Bernstein.
diff --git a/WebCore/svg/SVGTextElement.cpp b/WebCore/svg/SVGTextElement.cpp
index c8f280e..e0b4366 100644
--- a/WebCore/svg/SVGTextElement.cpp
+++ b/WebCore/svg/SVGTextElement.cpp
@@ -86,7 +86,7 @@ AffineTransform SVGTextElement::getScreenCTM(StyleUpdateStrategy styleUpdateStra
AffineTransform SVGTextElement::animatedLocalTransform() const
{
- return m_supplementalTransform ? transform()->concatenate().matrix() * *m_supplementalTransform : transform()->concatenate().matrix();
+ return m_supplementalTransform ? *m_supplementalTransform * transform()->concatenate().matrix() : transform()->concatenate().matrix();
}
AffineTransform* SVGTextElement::supplementalTransform()
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list