Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(210)

Unified Diff: LayoutTests/svg/custom/getBBox-use.html

Issue 1310873004: Include additional translation in getBBox for SVGUseElement (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: LayoutTests/svg/custom/getBBox-use.html
diff --git a/LayoutTests/svg/custom/getBBox-use.html b/LayoutTests/svg/custom/getBBox-use.html
new file mode 100644
index 0000000000000000000000000000000000000000..bec669e25589dc3034d8dd11a8d660645b48b71e
--- /dev/null
+++ b/LayoutTests/svg/custom/getBBox-use.html
@@ -0,0 +1,16 @@
+<!DOCTYPE html>
+<script src="../../resources/testharness.js"></script>
+<script src="../../resources/testharnessreport.js"></script>
+<svg height="0">
+ <rect id="r" width="300" height="400"/>
+ <use xlink:href="#r" x="100" y="200"/>
+</svg>
+<script>
+test(function() {
+ var useBBox = document.querySelector('use').getBBox();
+ assert_equals(useBBox.x, 100);
+ assert_equals(useBBox.y, 200);
+ assert_equals(useBBox.width, 300);
+ assert_equals(useBBox.height, 400);
+}, 'Additional translation affects bounding box of <use>');
+</script>

Powered by Google App Engine
This is Rietveld 408576698