[lasem] tests: add aspect-ratio test file in suite.



commit 1400a0c44d68bffe75b2be3535751990e59f90e2
Author: Emmanuel Pacaud <emmanuel gnome org>
Date:   Sat Oct 27 18:56:03 2012 +0200

    tests: add aspect-ratio test file in suite.

 tests/data/svg/suite/coords/aspect-ratio-ref.png |  Bin 0 -> 7808 bytes
 tests/data/svg/suite/coords/aspect-ratio.svg     |  131 ++++++++++++++++++++++
 2 files changed, 131 insertions(+), 0 deletions(-)
---
diff --git a/tests/data/svg/suite/coords/aspect-ratio-ref.png b/tests/data/svg/suite/coords/aspect-ratio-ref.png
new file mode 100644
index 0000000..140107b
Binary files /dev/null and b/tests/data/svg/suite/coords/aspect-ratio-ref.png differ
diff --git a/tests/data/svg/suite/coords/aspect-ratio.svg b/tests/data/svg/suite/coords/aspect-ratio.svg
new file mode 100755
index 0000000..be836b2
--- /dev/null
+++ b/tests/data/svg/suite/coords/aspect-ratio.svg
@@ -0,0 +1,131 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1 Basic//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11-basic.dtd"; [
+	<!ENTITY Smile "
+<rect x='.5' y='.5' width='29' height='39' fill='black' stroke='red'/>
+<g transform='translate(0, 5)'>
+<circle cx='15' cy='15' r='10' fill='yellow'/>
+<circle cx='12' cy='12' r='1.5' fill='black'/>
+<circle cx='17' cy='12' r='1.5' fill='black'/>
+<path d='M 10 19 L 15 23 20 19' stroke='black' stroke-width='2'/>
+</g>
+">
+	<!ENTITY Viewport1 "<rect x='.5' y='.5' width='49' height='29'
+fill='none' stroke='blue'/>">
+	<!ENTITY Viewport2 "<rect x='.5' y='.5' width='29' height='59'
+fill='none' stroke='blue'/>">
+]>
+<!--======================================================================-->
+<!--=  Copyright 2000 World Wide Web Consortium, (Massachusetts          =-->
+<!--=  Institute of Technology, Institut National de Recherche en        =-->
+<!--=  Informatique et en Automatique, Keio University). All Rights      =-->
+<!--=  Reserved. See http://www.w3.org/Consortium/Legal/.                =-->
+<!--======================================================================-->
+<!-- ===================================================================== -->
+<!-- The content of this test is taken from the SVG specification. The     -->
+<!-- original author is Jon Ferraiolo.                                     -->
+<!-- coords-viewBox-BE-03.svg                                              -->
+<!-- renamed for 1.1 suite to coords-viewattr-01-b.svg                     -->
+<!-- Author : Vincent Hardy                                                -->
+<!-- Modified for svg 1.1 by Ola Andersson, 07-Mar-2002                    -->
+<!--======================================================================-->
+<svg version="1.1" baseProfile="basic" xmlns="http://www.w3.org/2000/svg"; xmlns:xlink="http://www.w3.org/1999/xlink"; id="svg-root" width="100%" height="100%" viewBox="0 0 480 360">
+	<SVGTestCase xmlns="http://www.w3.org/2000/02/svg/testsuite/description/";>
+		<OperatorScript version="$Revision: 1.6 $" testname="coords-viewattr-01-b.svg">
+			<Paragraph>
+            This test verifies the implementation of the viewBox and the preserveAspectRatio attribute.
+         This is a modified version of the sample file included in the SVG specification.
+         It exercises the various preserveAspectRatio values and uses a general entity definition
+         in order to make reading of the SVG source easier.
+         </Paragraph>
+			<Paragraph>
+         The rendered picture should match the reference image exactly except for variations in the labeling text.
+         </Paragraph>
+		</OperatorScript>
+	</SVGTestCase>
+	<title id="test-title">coords-viewattr-01-b</title>
+	<desc id="test-desc">Validates viewBox specification and the preserveAspectRatio attribute</desc>
+	<!--======================================================================-->
+	<!--Content of Test Case follows...                  =====================-->
+	<!--======================================================================-->
+	<g id="test-body-content" transform="translate(0, 30)">
+		<g font-size="9">
+			<desc>Example PreserveAspectRatio - demonstrate available options</desc>
+<!--                        <text x="10" y="30">SVG to fit</text>-->
+			<g transform="translate(20,40)">&Smile;</g>
+<!--                        <text x="10" y="110">Viewport 1</text>-->
+			<g transform="translate(10,120)">&Viewport1;</g>
+<!--                        <text x="10" y="180">Viewport 2</text>-->
+			<g transform="translate(20,190)">&Viewport2;</g>
+			<g id="meet-group-1" transform="translate(120, 50)">
+				<g>
+<!--                                        <text y="-5">xMin*</text>-->
+					&Viewport1;
+          <svg version="1.1" xmlns="http://www.w3.org/2000/svg"; xmlns:xlink="http://www.w3.org/1999/xlink"; preserveAspectRatio="xMinYMin meet" viewBox="0 0 30 40" width="50" height="30">&Smile;</svg>
+				</g>
+				<g transform="translate(70,0)">
+<!--                                        <text y="-5">xMid*</text>-->
+					&Viewport1;
+          <svg version="1.1" xmlns="http://www.w3.org/2000/svg"; xmlns:xlink="http://www.w3.org/1999/xlink"; preserveAspectRatio="xMidYMid meet" viewBox="0 0 30 40" width="50" height="30">&Smile;</svg>
+				</g>
+				<g transform="translate(0,50)">
+<!--                                        <text y="-5">xMax*</text>-->
+					&Viewport1;
+          <svg version="1.1" xmlns="http://www.w3.org/2000/svg"; xmlns:xlink="http://www.w3.org/1999/xlink"; preserveAspectRatio="xMaxYMax meet" viewBox="0 0 30 40" width="50" height="30">&Smile;</svg>
+				</g>
+			</g>
+			<g id="meet-group-2" transform="translate(300, 50)">
+				<g>
+<!--                                        <text y="-5">*YMin</text>-->
+					&Viewport2;
+          <svg version="1.1" xmlns="http://www.w3.org/2000/svg"; xmlns:xlink="http://www.w3.org/1999/xlink"; preserveAspectRatio="xMinYMin meet" viewBox="0 0 30 40" width="30" height="60">&Smile;</svg>
+				</g>
+				<g transform="translate(50, 0)">
+<!--                                        <text y="-5">*YMid</text>-->
+					&Viewport2;
+          <svg version="1.1" xmlns="http://www.w3.org/2000/svg"; xmlns:xlink="http://www.w3.org/1999/xlink"; preserveAspectRatio="xMidYMid meet" viewBox="0 0 30 40" width="30" height="60">&Smile;</svg>
+				</g>
+				<g transform="translate(100, 0)">
+<!--                                        <text y="-5">*YMax</text>-->
+					&Viewport2;
+          <svg version="1.1" xmlns="http://www.w3.org/2000/svg"; xmlns:xlink="http://www.w3.org/1999/xlink"; preserveAspectRatio="xMaxYMax meet" viewBox="0 0 30 40" width="30" height="60">&Smile;</svg>
+				</g>
+			</g>
+			<g id="slice-group-1" transform="translate(120, 185)">
+				<g>
+<!--                                        <text y="-5">xMin*</text>-->
+					&Viewport2;
+          <svg version="1.1" xmlns="http://www.w3.org/2000/svg"; xmlns:xlink="http://www.w3.org/1999/xlink"; preserveAspectRatio="xMinYMin slice" viewBox="0 0 30 40" width="30" height="60">&Smile;</svg>
+				</g>
+				<g transform="translate(50,0)">
+<!--                                        <text y="-5">xMid*</text>-->
+					&Viewport2;
+          <svg version="1.1" xmlns="http://www.w3.org/2000/svg"; xmlns:xlink="http://www.w3.org/1999/xlink"; preserveAspectRatio="xMidYMid slice" viewBox="0 0 30 40" width="30" height="60">&Smile;</svg>
+				</g>
+				<g transform="translate(100,0)">
+<!--                                        <text y="-5">xMax*</text>-->
+					&Viewport2;
+          <svg version="1.1" xmlns="http://www.w3.org/2000/svg"; xmlns:xlink="http://www.w3.org/1999/xlink"; preserveAspectRatio="xMaxYMax slice" viewBox="0 0 30 40" width="30" height="60">&Smile;</svg>
+				</g>
+			</g>
+			<g id="slide-group-2" transform="translate(300, 155) translate(0, 30)">
+				<g>
+<!--                                        <text y="-5">*YMin</text>-->
+					&Viewport1;
+          <svg version="1.1" xmlns="http://www.w3.org/2000/svg"; xmlns:xlink="http://www.w3.org/1999/xlink"; preserveAspectRatio="xMinYMin slice" viewBox="0 0 30 40" width="50" height="30">&Smile;</svg>
+				</g>
+				<g transform="translate(70,0)">
+<!--                                        <text y="-5">*YMid</text>-->
+					&Viewport1;
+          <svg version="1.1" xmlns="http://www.w3.org/2000/svg"; xmlns:xlink="http://www.w3.org/1999/xlink"; preserveAspectRatio="xMidYMid slice" viewBox="0 0 30 40" width="50" height="30">&Smile;</svg>
+				</g>
+				<g transform="translate(0,50)">
+<!--                                        <text y="-5">*YMax</text>-->
+					&Viewport1;
+          <svg version="1.1" xmlns="http://www.w3.org/2000/svg"; xmlns:xlink="http://www.w3.org/1999/xlink"; preserveAspectRatio="xMaxYMax slice" viewBox="0 0 30 40" width="50" height="30">&Smile;</svg>
+				</g>
+			</g>
+		</g>
+	</g>
+<!--        <text id="revision" x="10" y="340" font-size="40" stroke="none" fill="black">$Revision: 1.6 $</text>-->
+<!--        <rect id="test-frame" x="1" y="1" width="478" height="358" fill="none" stroke="#000000"/>-->
+</svg>



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]