mapnik/tests/visual_tests/styles/group-symbolizer-line-2.xml
2014-12-09 20:13:38 +00:00

109 lines
3.5 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<!-- Without unlock-image -->
<!DOCTYPE Map>
<Map background-color="green" srs="+proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs" minimum-version="2.0.0">
<Parameters>
<Parameter name="sizes">512,512</Parameter>
</Parameters>
<!-- the aim here is to test the "repeat-key" parameter. it is
supposed to stop collidable / placeable items from being
too close, even if they're on different features. -->
<Layer name="alpha" srs="+proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs">
<StyleName>alpha</StyleName>
<Datasource>
<Parameter name="type">csv</Parameter>
<Parameter name="inline">
wkt,key1,key2
"POINT(3.3 0)",foo,1
"POINT(6.7 0)",bar,2
</Parameter>
</Datasource>
</Layer>
<Style name="alpha">
<Rule>
<PointSymbolizer ignore-placement="true"/>
<GroupSymbolizer start-column="1" num-columns="1" placement="point" avoid-edges="false" repeat-key="[key%]">
<PairLayout item-margin="1"/>
<GroupRule>
<ShieldSymbolizer file="../../data/svg/rect.svg" face-name="DejaVu Sans Book" size="10" minimum-distance="1" placement="point" dy="0" fill="#ff0000">[key%]</ShieldSymbolizer>
</GroupRule>
</GroupSymbolizer>
</Rule>
</Style>
<Layer name="beta" srs="+proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs">
<StyleName>beta</StyleName>
<Datasource>
<Parameter name="type">csv</Parameter>
<Parameter name="inline">
wkt,name1,ref1,name2,ref2
"LINESTRING(0 -0.6, 10 -0.6)",One,1,Two,2
"LINESTRING(0 -1.2, 10 -1.2)",One,1,Two,2
"LINESTRING(0 -1.8, 10 -1.8)",One,1,Two,2
"LINESTRING(0 -2.4, 10 -2.4)",One,1,Two,2
</Parameter>
</Datasource>
</Layer>
<Style name="beta">
<Rule>
<GroupSymbolizer start-column="1" num-columns="1" placement="line" avoid-edges="false" repeat-distance="20" spacing="1" repeat-key="bar">
<PairLayout item-margin="1"/>
<GroupRule>
<ShieldSymbolizer file="../../data/svg/rect.svg" face-name="DejaVu Sans Book" size="10" placement="point" dy="0" fill="#ffffff">bar</ShieldSymbolizer>
</GroupRule>
</GroupSymbolizer>
</Rule>
</Style>
<Layer name="gamma" srs="+proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs">
<StyleName>gamma</StyleName>
<Datasource>
<Parameter name="type">csv</Parameter>
<Parameter name="inline">
wkt,name1,ref1,name2,ref2
"LINESTRING(0 0.6, 10 0.6)",One,1,Two,2
"LINESTRING(0 1.2, 10 1.2)",One,1,Two,2
"LINESTRING(0 1.8, 10 1.8)",One,1,Two,2
"LINESTRING(0 2.4, 10 2.4)",One,1,Two,2
</Parameter>
</Datasource>
</Layer>
<Style name="gamma">
<Rule>
<GroupSymbolizer start-column="1" num-columns="1" placement="line" avoid-edges="false" repeat-distance="20" spacing="1" repeat-key="foo">
<PairLayout item-margin="1"/>
<GroupRule>
<ShieldSymbolizer file="../../data/svg/rect.svg" face-name="DejaVu Sans Book" size="10" placement="point" dy="0" fill="#000000">foo</ShieldSymbolizer>
</GroupRule>
</GroupSymbolizer>
</Rule>
</Style>
<!-- for framing -->
<Layer name="frame" srs="+proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs">
<StyleName>frame</StyleName>
<Datasource>
<Parameter name="type">csv</Parameter>
<Parameter name="inline">
wkt,nr
"POINT(0 5)",1
"POINT(0 -5)",2
"POINT(10 5)",3
"POINT(10 -5)",4
</Parameter>
</Datasource>
</Layer>
<Style name="frame">
<Rule>
<PointSymbolizer/>
<DebugSymbolizer/>
</Rule>
</Style>
</Map>