layout/reftests/image-rect/background-over-size-rect.html

Thu, 15 Jan 2015 21:03:48 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 15 Jan 2015 21:03:48 +0100
branch
TOR_BUG_9701
changeset 11
deefc01c0e14
permissions
-rw-r--r--

Integrate friendly tips from Tor colleagues to make (or not) 4.5 alpha 3;
This includes removal of overloaded (but unused) methods, and addition of
a overlooked call to DataStruct::SetData(nsISupports, uint32_t, bool.)

michael@0 1 <!DOCTYPE html>
michael@0 2 <!--
michael@0 3 Any copyright is dedicated to the Public Domain.
michael@0 4 http://creativecommons.org/licenses/publicdomain/
michael@0 5
michael@0 6 Tests image rects that run off the source image bounds.
michael@0 7 -->
michael@0 8 <html>
michael@0 9 <head>
michael@0 10 <title>Testcases: -moz-image-rect() [bug 113577]</title>
michael@0 11 <style>
michael@0 12 div.wrapper {
michael@0 13 width: 32px;
michael@0 14 height: 32px;
michael@0 15 margin: 10px;
michael@0 16 background-color: red;
michael@0 17 }
michael@0 18 div.wrapper div {
michael@0 19 width: 32px;
michael@0 20 height: 32px;
michael@0 21 background: no-repeat;
michael@0 22 }
michael@0 23 /* The final crop rect is computed by intersecting an image rect and the
michael@0 24 source image bounds, so the following tests should display the bottom
michael@0 25 right 16x16 corner of the image. */
michael@0 26 #test1 {
michael@0 27 background-image: -moz-image-rect(url(green-16x16-in-blue-32x32.png), 16, 50, 50, 16);
michael@0 28 }
michael@0 29 #test2 {
michael@0 30 background-image: -moz-image-rect(url(green-16x16-in-blue-32x32.png), 50.000001%, 1000000%, 1000000%, 50.000001%);
michael@0 31 }
michael@0 32 </style>
michael@0 33 </head>
michael@0 34 <body>
michael@0 35 <div class="wrapper"><div id="test1"></div></div>
michael@0 36 <div class="wrapper"><div id="test2"></div></div>
michael@0 37 </body>
michael@0 38 </html>

mercurial