[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.2.3-2-25-gb2c19be
Gustavo Noronha Silva
gns at gnome.org
Mon Sep 6 13:09:18 UTC 2010
The following commit has been merged in the debian/unstable branch:
commit e68c7098411c0a3ff70cdc08e613b1a5e795b1fd
Author: simon.fraser at apple.com <simon.fraser at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Sat Jun 12 00:52:38 2010 +0000
2010-06-10 Abhishek Arya <inferno at chromium.org>
Reviewed by Dave Hyatt.
Do not render CSS Styles :first-letter and :first-line in a SVG text element context.
https://bugs.webkit.org/show_bug.cgi?id=40031
Test: svg/text/text-style-invalid.svg
* rendering/RenderSVGText.cpp:
(WebCore::RenderSVGText::firstLineBlock):
(WebCore::RenderSVGText::updateFirstLetter):
* rendering/RenderSVGText.h:
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@61050 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index 5f8dd65..10a3bab 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,5 +1,15 @@
2010-06-11 Abhishek Arya <inferno at chromium.org>
+ Reviewed by Dave Hyatt.
+
+ Tests that we do not crash while rendering SVG text with CSS styles :first-letter and :first-line.
+ https://bugs.webkit.org/show_bug.cgi?id=40031
+
+ * svg/text/text-style-invalid-expected.txt: Added.
+ * svg/text/text-style-invalid.svg: Added.
+
+2010-06-11 Abhishek Arya <inferno at chromium.org>
+
Reviewed by David Hyatt.
Tests that we do not crash when clearing floats during SVG load.
diff --git a/LayoutTests/svg/text/text-style-invalid.svg b/LayoutTests/svg/text/text-style-invalid.svg
new file mode 100644
index 0000000..c4f0acb
--- /dev/null
+++ b/LayoutTests/svg/text/text-style-invalid.svg
@@ -0,0 +1,16 @@
+<svg xmlns="http://www.w3.org/2000/svg">
+ <foreignObject>
+ <body xmlns="http://www.w3.org/1999/xhtml">
+ <div style="position:absolute">This test passes if we do NOT crash while rendering SVG text with CSS styles :first-letter and :first-line.</div>
+ </body>
+ </foreignObject>
+ <style>
+ text:first-letter { color: red }
+ text:first-line { color: red }
+ </style>
+ <text x="10" y="50">Some text</text>
+ <script>
+ if (window.layoutTestController)
+ layoutTestController.dumpAsText();
+ </script>
+</svg>
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 24a318f..595bcfd 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,17 @@
+2010-06-10 Abhishek Arya <inferno at chromium.org>
+
+ Reviewed by Dave Hyatt.
+
+ Do not render CSS Styles :first-letter and :first-line in a SVG text element context.
+ https://bugs.webkit.org/show_bug.cgi?id=40031
+
+ Test: svg/text/text-style-invalid.svg
+
+ * rendering/RenderSVGText.cpp:
+ (WebCore::RenderSVGText::firstLineBlock):
+ (WebCore::RenderSVGText::updateFirstLetter):
+ * rendering/RenderSVGText.h:
+
2010-06-11 Abhishek Arya <inferno at chromium.org>
Reviewed by David Hyatt.
diff --git a/WebCore/rendering/RenderSVGText.cpp b/WebCore/rendering/RenderSVGText.cpp
index 76b8b86..de902e0 100644
--- a/WebCore/rendering/RenderSVGText.cpp
+++ b/WebCore/rendering/RenderSVGText.cpp
@@ -225,6 +225,19 @@ FloatRect RenderSVGText::repaintRectInLocalCoordinates() const
return repaintRect;
}
+// Fix for <rdar://problem/8048875>. We should not render :first-line CSS Style
+// in a SVG text element context.
+RenderBlock* RenderSVGText::firstLineBlock() const
+{
+ return 0;
+}
+
+// Fix for <rdar://problem/8048875>. We should not render :first-letter CSS Style
+// in a SVG text element context.
+void RenderSVGText::updateFirstLetter()
+{
+}
+
}
#endif // ENABLE(SVG)
diff --git a/WebCore/rendering/RenderSVGText.h b/WebCore/rendering/RenderSVGText.h
index ab4b09b..f09e396 100644
--- a/WebCore/rendering/RenderSVGText.h
+++ b/WebCore/rendering/RenderSVGText.h
@@ -72,6 +72,9 @@ private:
virtual RootInlineBox* createRootInlineBox();
+ virtual RenderBlock* firstLineBlock() const;
+ virtual void updateFirstLetter();
+
AffineTransform m_localTransform;
};
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list