layout/reftests/bugs/234686-2.html

Wed, 31 Dec 2014 07:16:47 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 07:16:47 +0100
branch
TOR_BUG_9701
changeset 3
141e0f1194b1
permissions
-rw-r--r--

Revert simplistic fix pending revisit of Mozilla integration attempt.

michael@0 1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
michael@0 2 <!--
michael@0 3 From http://fantasai.inkedblade.net/style/specs/css2.1/tests/min-max-replaced
michael@0 4 with permission in
michael@0 5 https://bugzilla.mozilla.org/show_bug.cgi?id=413361#c11
michael@0 6 -->
michael@0 7 <html lang="en">
michael@0 8 <head>
michael@0 9 <title>CSS 2.1 Test Suite: Min/Max Height and Width Constraints on Replaced Elements</title>
michael@0 10 <link rel="author" title="fantasai" href="http://fantasai.inkedblade.net/" />
michael@0 11 <link rel="help" href="http://www.w3.org/TR/CSS21/visudet.html#min-max-widths" />
michael@0 12 <meta name="assert" content="However, for replaced elements with an intrinsic ratio and both 'width' and 'height' specified as 'auto', the algorithm is as follows:" />
michael@0 13 <style type="text/css">
michael@0 14
michael@0 15 /* Diagrams are scaled so that w and h line up.
michael@0 16 Image is 75px x 75px; target dimensions will thus be 75px. */
michael@0 17
michael@0 18 /* w > max-width
michael@0 19 * wmax/w > hmin/h
michael@0 20 * wmax w
michael@0 21 * |------------------+------+----------------> width
michael@0 22 * hmin h
michael@0 23 * |------------+------------+----------------> height
michael@0 24 *
michael@0 25 * target: [wmax, wmax * h/w]
michael@0 26 */
michael@0 27
michael@0 28 #img2 {max-width: 75px; /* 50% */
michael@0 29 min-height: 60px; /* 40% */}
michael@0 30
michael@0 31 </style>
michael@0 32 </head>
michael@0 33 <body>
michael@0 34 <p><img src="234686-2.gif" alt="" id="img2"></p> <!-- w=150 h=150 -->
michael@0 35
michael@0 36 </body>
michael@0 37 </html>

mercurial