layout/reftests/svg/non-scaling-stroke-02-ref.svg

Fri, 16 Jan 2015 18:13:44 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Fri, 16 Jan 2015 18:13:44 +0100
branch
TOR_BUG_9701
changeset 14
925c144e1f1f
permissions
-rw-r--r--

Integrate suggestion from review to improve consistency with existing code.

     1 <svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" overflow="hidden">
     2 <style type="text/css" >
     3 rect {
     4   stroke-width: 30px;
     5 }
     6 </style>
     7 <defs>
     8   <linearGradient id="grad1" x1="0%" y1="0%" x2="100%" y2="100%">
     9     <stop offset="0" stop-color="blue"/>
    10     <stop offset="1" stop-color="yellow"/>
    11   </linearGradient>
    12   <linearGradient id="grad2" x1="360" y1="500" x2="560" y2="600" gradientUnits="userSpaceOnUse" gradientTransform="scale(0.25,1)">
    13     <stop offset="0" stop-color="blue"/>
    14     <stop offset="1" stop-color="yellow"/>
    15   </linearGradient>
    16   <pattern id="pattern" x="0" y="0" width="40" height="40" patternUnits="userSpaceOnUse" patternTransform="scale(1,0.5), skewX(45)">
    17     <rect x="0" y="0" width="20" height="20" fill="red"/>
    18     <rect x="20" y="0" width="20" height="20" fill="green"/>
    19     <rect x="0" y="20" width="20" height="20" fill="blue"/>
    20     <rect x="20" y="20" width="20" height="20" fill="yellow"/>
    21   </pattern>
    22   <rect id="rect" width="200" height="100" fill="none"/>
    23 </defs>
    25 <rect x="40" y="40" width="200" height="100" fill="none" stroke="url(#grad1)"/>
    27 <rect x="40" y="200" width="200" height="100" fill="none" stroke="url(#grad2)" />
    29 <use xlink:href="#rect" transform="translate(40, 360)" stroke="url(#pattern)"/>
    31 <use xlink:href="#rect" x="40" y="520" stroke="green"/>
    33 </svg>

mercurial