Add visual test for ShieldSymbolizer.
This commit is contained in:
parent
980cdd9e92
commit
212171b9ee
3 changed files with 123 additions and 12 deletions
BIN
tests/data/images/crosshair16x16.png
Normal file
BIN
tests/data/images/crosshair16x16.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 216 B |
91
tests/data/svg/crosshair16x16.svg
Normal file
91
tests/data/svg/crosshair16x16.svg
Normal file
|
@ -0,0 +1,91 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||
|
||||
<svg
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
width="16"
|
||||
height="16"
|
||||
id="svg2"
|
||||
version="1.1"
|
||||
inkscape:version="0.48.1 r9760"
|
||||
sodipodi:docname="crosshair16x16.svg">
|
||||
<defs
|
||||
id="defs4">
|
||||
<inkscape:path-effect
|
||||
effect="spiro"
|
||||
id="path-effect4389"
|
||||
is_visible="true" />
|
||||
<marker
|
||||
inkscape:stockid="Arrow1Lstart"
|
||||
orient="auto"
|
||||
refY="0.0"
|
||||
refX="0.0"
|
||||
id="Arrow1Lstart"
|
||||
style="overflow:visible">
|
||||
<path
|
||||
id="path3764"
|
||||
d="M 0.0,0.0 L 5.0,-5.0 L -12.5,0.0 L 5.0,5.0 L 0.0,0.0 z "
|
||||
style="fill-rule:evenodd;stroke:#000000;stroke-width:1.0pt;marker-start:none"
|
||||
transform="scale(0.8) translate(12.5,0)" />
|
||||
</marker>
|
||||
<inkscape:path-effect
|
||||
effect="spiro"
|
||||
id="path-effect2991"
|
||||
is_visible="true" />
|
||||
</defs>
|
||||
<sodipodi:namedview
|
||||
id="base"
|
||||
pagecolor="#ffffff"
|
||||
bordercolor="#666666"
|
||||
borderopacity="1.0"
|
||||
inkscape:pageopacity="0.0"
|
||||
inkscape:pageshadow="2"
|
||||
inkscape:zoom="22.4"
|
||||
inkscape:cx="6.3030809"
|
||||
inkscape:cy="8.2034582"
|
||||
inkscape:document-units="px"
|
||||
inkscape:current-layer="layer1"
|
||||
showgrid="false"
|
||||
inkscape:window-width="1216"
|
||||
inkscape:window-height="753"
|
||||
inkscape:window-x="0"
|
||||
inkscape:window-y="25"
|
||||
inkscape:window-maximized="1" />
|
||||
<metadata
|
||||
id="metadata7">
|
||||
<rdf:RDF>
|
||||
<cc:Work
|
||||
rdf:about="">
|
||||
<dc:format>image/svg+xml</dc:format>
|
||||
<dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||
<dc:title></dc:title>
|
||||
</cc:Work>
|
||||
</rdf:RDF>
|
||||
</metadata>
|
||||
<g
|
||||
inkscape:label="Layer 1"
|
||||
inkscape:groupmode="layer"
|
||||
id="layer1">
|
||||
<path
|
||||
style="fill:none;stroke:#ff0000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
|
||||
d="M 0,8 16,8"
|
||||
id="path4387"
|
||||
inkscape:path-effect="#path-effect4389"
|
||||
inkscape:original-d="M 0,8 16,8"
|
||||
inkscape:connector-curvature="0" />
|
||||
<path
|
||||
inkscape:connector-curvature="0"
|
||||
inkscape:original-d="M 8,0 8,16"
|
||||
inkscape:path-effect="#path-effect4389"
|
||||
id="path4391"
|
||||
d="M 8,0 8,16"
|
||||
style="fill:none;stroke:#ff0000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 2.7 KiB |
|
@ -1,19 +1,39 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!DOCTYPE Map>
|
||||
<Map background-color="white" srs="+proj=latlong +datum=WGS84">
|
||||
<Map background-color="green" srs="+proj=latlong +datum=WGS84">
|
||||
|
||||
<Layer name="layer" srs="+proj=latlong +datum=WGS84">
|
||||
<StyleName>My Style</StyleName>
|
||||
<Datasource>
|
||||
<Parameter name="type">shape</Parameter>
|
||||
<Parameter name="file">points.shp</Parameter>
|
||||
</Datasource>
|
||||
</Layer>
|
||||
<Layer name="layer" srs="+proj=latlong +datum=WGS84">
|
||||
<StyleName>My Style</StyleName>
|
||||
<Datasource>
|
||||
<Parameter name="type">shape</Parameter>
|
||||
<Parameter name="file">points.shp</Parameter>
|
||||
</Datasource>
|
||||
</Layer>
|
||||
|
||||
<Style name="My Style">
|
||||
<Rule>
|
||||
<ShieldSymbolizer face-name="DejaVu Sans Book" size="16" placement="point" file="../data/svg/rect.svg" dx="0" dy="-5">'x'</ShieldSymbolizer>
|
||||
</Rule>
|
||||
</Style>
|
||||
<Rule>
|
||||
<Filter>[nr] = '1'</Filter>
|
||||
<ShieldSymbolizer face-name="DejaVu Sans Book" size="16" placement="point" file="../data/images/crosshair16x16.png">'x'</ShieldSymbolizer>
|
||||
</Rule>
|
||||
<Rule>
|
||||
<Filter>[nr] = '3'</Filter>
|
||||
<ShieldSymbolizer face-name="DejaVu Sans Book" size="16" placement="point" file="../data/svg/crosshair16x16.svg">'x'</ShieldSymbolizer>
|
||||
</Rule>
|
||||
<Rule>
|
||||
<Filter>[nr] = '5'</Filter>
|
||||
<ShieldSymbolizer face-name="DejaVu Sans Book" size="16" placement="point" fill="red" file="../data/images/checker.jpg" allow-overlap="true">'x'</ShieldSymbolizer>
|
||||
</Rule>
|
||||
<Rule>
|
||||
<Filter>[nr] = '7'</Filter>
|
||||
<ShieldSymbolizer face-name="DejaVu Sans Book" size="16" placement="point" file="../data/svg/rect.svg" allow-overlap="true">'x'</ShieldSymbolizer>
|
||||
</Rule>
|
||||
<Rule>
|
||||
<Filter>[nr] = '9'</Filter>
|
||||
<ShieldSymbolizer face-name="DejaVu Sans Book" size="16" placement="point" file="../data/images/dummy.png">'x'</ShieldSymbolizer>
|
||||
</Rule>
|
||||
<Rule>
|
||||
<PointSymbolizer allow-overlap="true" file="../data/raster/white-alpha.png"/>
|
||||
</Rule>
|
||||
</Style>
|
||||
|
||||
</Map>
|
||||
|
|
Loading…
Add table
Reference in a new issue