blob: b77d535d62f76abb7f083d79af04c22e17eee25d [file] [log] [blame]
<?xml version="1.0" standalone="no"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<!-- ====================================================================== -->
<!-- Test for the color functions introduced with SVG Color 1.2 -->
<!-- http://www.w3.org/TR/SVGColor12 -->
<!-- -->
<!-- @version $Id$ -->
<!-- ====================================================================== -->
<?xml-stylesheet type="text/css" href="../../resources/style/test.css" ?>
<svg id="body" width="450" height="500" viewBox="0 0 450 500"
xmlns="http://www.w3.org/2000/svg" version="1.2"
xmlns:xlink="http://www.w3.org/1999/xlink" >
<title>SVG Color 1.2 Test</title>
<!-- ============================================================= -->
<!-- Test content -->
<!-- ============================================================= -->
<defs/>
<g id="testContent" class="legend" style="text-anchor:middle">
<text x="225" y="40" class="title">
SVG Color 1.2 Functions (Device-specific Colors)
</text>
<g stroke="black" stroke-width="2" transform="translate(35, 90)">
<rect y="0" width="40" height="40" fill="#FF0000 device-gray(0.4)"/>
<rect y="60" width="40" height="40" fill="#FF0000 device-rgb(153, 153, 122)"/>
<rect y="120" width="40" height="40" fill="#FF0000 device-cmyk(0.0,0.0,0.2,0.4)"/>
<rect y="180" width="40" height="40" fill="#FF0000 device-nchannel(0.5,1.0)"/>
</g>
<!--
Unsupported color functions or missing profiles will result in the boxes appearing
red meaning that the sRGB fallback was used. All but the second box of the four
should be a darker yellow.
-->
<g text-anchor="start" transform="translate(90, 110)">
<text y="0">
<tspan>#FF0000 device-gray(0.4)</tspan>
<tspan x="0" dy="12">Gray where device-specific colors are supported, red otherwise.</tspan>
</text>
<text y="60">
<tspan>#FF0000 device-rgb(153, 153, 122)</tspan>
<tspan x="0" dy="12">Khaki where device-specific colors are supported, red otherwise.</tspan>
</text>
<text y="120">
<tspan>#FF0000 device-cmyk(0.0,0.0,0.2,0.4)</tspan>
<tspan x="0" dy="12">Khaki where device-specific colors are supported, red otherwise.</tspan>
</text>
<text y="180">
<tspan>#FF0000 device-nchannel(0.5,1.0)</tspan>
<tspan x="0" dy="12">Some device-dependent color where device-specific colors are</tspan>
<tspan x="0" dy="12">supported, red otherwise.</tspan>
</text>
</g>
</g>
<!-- ============================================================= -->
<!-- Batik sample mark -->
<!-- ============================================================= -->
<use xlink:href="../../../batikLogo.svg#Batik_Tag_Box" />
</svg>