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

Unified Diff: third_party/WebKit/LayoutTests/svg/css/background-non-integer-viewbox.html

Issue 1912063004: Align image sizes for SVG with raster image size (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add NeedsManualRebaseline to tests Created 4 years, 8 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: third_party/WebKit/LayoutTests/svg/css/background-non-integer-viewbox.html
diff --git a/third_party/WebKit/LayoutTests/svg/css/background-non-integer-viewbox.html b/third_party/WebKit/LayoutTests/svg/css/background-non-integer-viewbox.html
new file mode 100644
index 0000000000000000000000000000000000000000..dff2d88c752506a3208fecdaf88d350fd73380b5
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/svg/css/background-non-integer-viewbox.html
@@ -0,0 +1,79 @@
+<!DOCTYPE html>
+<title>Test SVG in CSS backgrounds with non-integer viewBox dimensions</title>
+<style>
+body {
+ margin: 0;
+}
+div {
+ display: inline-block;
+}
+#t1 {
+ background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 81.914 81.859"><rect width="81.914" height="40"/></svg>');
+ width: 8px;
+ height: 8px;
+}
+#t2 {
+ background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 81.914 81.859"><rect width="81.914" height="40"/></svg>');
+ width: 16px;
+ height: 16px;
+}
+#t3 {
+ background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 81.914 81.859"><rect width="81.914" height="40"/></svg>');
+ width: 32px;
+ height: 32px;
+}
+#t4 {
+ background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 81.914 81.859"><rect width="81.914" height="40"/></svg>');
+ width: 64px;
+ height: 64px;
+}
+#t5 {
+ background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 81.914 81.859"><rect width="81.914" height="40"/></svg>');
+ width: 128px;
+ height: 128px;
+}
+#t6 {
+ background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1 0.95"><rect width="1" height="0.5"/></svg>');
+ width: 8px;
+ height: 8px;
+}
+#t7 {
+ background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1 0.97"><rect width="1" height="0.5"/></svg>');
+ width: 16px;
+ height: 16px;
+}
+#t8 {
+ background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1 0.99"><rect width="1" height="0.5"/></svg>');
+ width: 32px;
+ height: 32px;
+}
+#t9 {
+ background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1 0.993"><rect width="1" height="0.5"/></svg>');
+ width: 64px;
+ height: 64px;
+}
+#t10 {
+ background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1 0.997"><rect width="1" height="0.5"/></svg>');
+ width: 128px;
+ height: 128px;
+}
+#cover {
+ position: absolute;
+ left: 0;
+ width: 600px;
+ top: 0;
+ height: 127px; /* We're only interested in the 128:th row. */
+ background-color: blue;
+}
+</style>
+<div id="t1"></div>
+<div id="t2"></div>
+<div id="t3"></div>
+<div id="t4"></div>
+<div id="t5"></div>
+<div id="t6"></div>
+<div id="t7"></div>
+<div id="t8"></div>
+<div id="t9"></div>
+<div id="t10"></div>
+<div id="cover"></div>

Powered by Google App Engine
This is Rietveld 408576698