| 1 |
<svg version="1.1" baseProfile="tiny" id="svg-root" |
| 2 |
width="100%" height="100%" viewBox="0 0 480 360" |
| 3 |
xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> |
| 4 |
<!--======================================================================--> |
| 5 |
<!--= SVG 1.1 2nd Edition Test Case =--> |
| 6 |
<!--======================================================================--> |
| 7 |
<!--= Copyright 2009 World Wide Web Consortium, (Massachusetts =--> |
| 8 |
<!--= Institute of Technology, European Research Consortium for =--> |
| 9 |
<!--= Informatics and Mathematics (ERCIM), Keio University). =--> |
| 10 |
<!--= All Rights Reserved. =--> |
| 11 |
<!--= See http://www.w3.org/Consortium/Legal/. =--> |
| 12 |
<!--======================================================================--> |
| 13 |
<d:SVGTestCase xmlns:d="http://www.w3.org/2000/02/svg/testsuite/description/" |
| 14 |
template-version="1.4" reviewer="AG" author="CN" status="issue" |
| 15 |
version="$Revision: 1.9 $" testname="$RCSfile: text-align-07-t.svg,v $"> |
| 16 |
<d:testDescription xmlns="http://www.w3.org/1999/xhtml" href="http://www.w3.org/TR/SVG11/text.html#AlignmentProperties"> |
| 17 |
<p>ISSUE - http://www.w3.org/2011/02/27-svg-irc#T22-20-51</p> |
| 18 |
<p> |
| 19 |
Test horizontal baselines across script and font size changes. |
| 20 |
</p> |
| 21 |
<p> |
| 22 |
Original test authored by Rodney Hardy at CISRA and modified by |
| 23 |
Anthony Grasso. |
| 24 |
</p> |
| 25 |
</d:testDescription> |
| 26 |
<d:operatorScript xmlns="http://www.w3.org/1999/xhtml"> |
| 27 |
<p> |
| 28 |
Run the test. No interaction required. |
| 29 |
</p> |
| 30 |
</d:operatorScript> |
| 31 |
<d:passCriteria xmlns="http://www.w3.org/1999/xhtml"> |
| 32 |
<p> |
| 33 |
The dominant baseline should be alphabetic, so the 'a' will be sitting |
| 34 |
on the blue line, the Japanese character '犜' will be on the ideographic baseline |
| 35 |
and 'ण' is a Devangari character and will use the hanging baseline. The |
| 36 |
smaller versions of the characters should be aligned to the same baselines. |
| 37 |
So the 'a's on the blue line, the Japanese characters slightly below the line |
| 38 |
and the Devangari characters should be hanging from the hanging baseline. |
| 39 |
</p> |
| 40 |
</d:passCriteria> |
| 41 |
</d:SVGTestCase> |
| 42 |
<title id="test-title">$RCSfile: text-align-07-t.svg,v $</title> |
| 43 |
<defs> |
| 44 |
<font-face font-family="SVGFreeSansASCII" unicode-range="U+0-7F"> |
| 45 |
<font-face-src> |
| 46 |
<font-face-uri xlink:href="../resources/SVGFreeSans.svg#ascii"/> |
| 47 |
</font-face-src> |
| 48 |
</font-face> |
| 49 |
</defs> |
| 50 |
<g id="test-body-content" font-family="SVGFreeSansASCII,sans-serif" font-size="18"> |
| 51 |
<g font-family="'Arial Unicode MS',Georgia,'Times New Roman',Times,'MS Mincho',serif" font-size="30"> |
| 52 |
<!-- |
| 53 |
The dominant baseline should be alphabetic, so the 'ab' will be sitting on the |
| 54 |
blue line, the japanese glyphs will be on the ideographic baseline and 'ण' |
| 55 |
is a devangari character and will use the hanging baseline. The smaller versions |
| 56 |
of the characters should be aligned to the same baselines. So 'ab' on the alphabetic |
| 57 |
base line, the ideographic chars slightly below the line and the devangari should be |
| 58 |
hanging from the hanging baseline. |
| 59 |
--> |
| 60 |
<text x="50" y="100" font-size="50"> |
| 61 |
a犜ण<tspan font-size="25">a犜ण</tspan><tspan font-size="10">a犜ण</tspan> |
| 62 |
</text> |
| 63 |
<line x1="50" y1="70" x2="400" y2="70" stroke-width="1" stroke="green"/> |
| 64 |
<text x="320" y="80" font-size="10" fill="green"> |
| 65 |
hanging base line |
| 66 |
</text> |
| 67 |
<line x1="50" y1="100" x2="400" y2="100" stroke-width="1" stroke="blue"/> |
| 68 |
<text x="310" y="110" font-size="10" fill="blue"> |
| 69 |
alphabetic base line |
| 70 |
</text> |
| 71 |
<line x1="50" y1="103" x2="250" y2="103" stroke-width="1" stroke="fuchsia"/> |
| 72 |
<text x="155" y="113" font-size="10" fill="fuchsia"> |
| 73 |
ideographic base line |
| 74 |
</text> |
| 75 |
</g> |
| 76 |
</g> |
| 77 |
<g font-family="SVGFreeSansASCII,sans-serif" font-size="32"> |
| 78 |
<text id="revision" x="10" y="340" stroke="none" fill="black">$Revision: 1.9 $</text> |
| 79 |
</g> |
| 80 |
<rect id="test-frame" x="1" y="1" width="478" height="358" fill="none" stroke="#000000"/> |
| 81 |
<!-- comment out this watermark once the test is approved --> |
| 82 |
<g id="draft-watermark"> |
| 83 |
<rect x="1" y="1" width="478" height="20" fill="red" stroke="black" stroke-width="1"/> |
| 84 |
<text font-family="SVGFreeSansASCII,sans-serif" font-weight="bold" font-size="20" x="240" |
| 85 |
text-anchor="middle" y="18" stroke-width="0.5" stroke="black" fill="white">DRAFT</text> |
| 86 |
</g> |
| 87 |
</svg> |