add tests for optional attr of symbolizers with images from 0.7.1-dev branch
This commit is contained in:
parent
7c0b28d4d7
commit
26c596cbf1
2 changed files with 56 additions and 2 deletions
|
@ -1,6 +1,6 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<!DOCTYPE Map >
|
<!DOCTYPE Map >
|
||||||
<Map bgcolor="#b5d0d0" srs="+proj=merc +datum=WGS84 +k=1.0 +units=m +over +no_defs" paths_from_xml="false">
|
<Map bgcolor="#b5d0d0" srs="+proj=merc +datum=WGS84 +k=1.0 +units=m +over +no_defs" min_version="0.7.1">
|
||||||
<Style name="test 1">
|
<Style name="test 1">
|
||||||
<Rule name="rule t1">
|
<Rule name="rule t1">
|
||||||
<Filter>[landuse] = 'meadow' or [landuse] = 'wood' or [landuse] = 'forest'</Filter>
|
<Filter>[landuse] = 'meadow' or [landuse] = 'wood' or [landuse] = 'forest'</Filter>
|
||||||
|
@ -12,7 +12,22 @@
|
||||||
<Rule title="foo">
|
<Rule title="foo">
|
||||||
<ElseFilter/>
|
<ElseFilter/>
|
||||||
<MaxScaleDenominator>1000000</MaxScaleDenominator>
|
<MaxScaleDenominator>1000000</MaxScaleDenominator>
|
||||||
<PointSymbolizer file="../data/images/dummy.png" type="png" width="16" height="16"/>
|
<PointSymbolizer file="../images/dummy.png" type="png" width="16" height="16"/>
|
||||||
|
</Rule>
|
||||||
|
</Style>
|
||||||
|
<Style name="test 3">
|
||||||
|
<Rule title="foo">
|
||||||
|
<PointSymbolizer file="../images/dummy.png" type="png"/>
|
||||||
|
</Rule>
|
||||||
|
</Style>
|
||||||
|
<Style name="test 4">
|
||||||
|
<Rule title="foo">
|
||||||
|
<PointSymbolizer file="../images/dummy.png" width="16" height="16"/>
|
||||||
|
</Rule>
|
||||||
|
</Style>
|
||||||
|
<Style name="test 5">
|
||||||
|
<Rule title="foo">
|
||||||
|
<PointSymbolizer file="../images/dummy.png"/>
|
||||||
</Rule>
|
</Rule>
|
||||||
</Style>
|
</Style>
|
||||||
</Map>
|
</Map>
|
||||||
|
|
39
tests/data/good_maps/point_symbolizer_on_polygon_map.xml
Normal file
39
tests/data/good_maps/point_symbolizer_on_polygon_map.xml
Normal file
|
@ -0,0 +1,39 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!DOCTYPE Map >
|
||||||
|
<Map bgcolor="#b5d0d0" min_version="0.7.1">
|
||||||
|
<Style name="test">
|
||||||
|
<Rule title="asia">
|
||||||
|
<Filter>([REGION]=142)</Filter>
|
||||||
|
<PointSymbolizer file="../images/dummy.png" allow_overlap="true"/>
|
||||||
|
</Rule>
|
||||||
|
<Rule title="europe">
|
||||||
|
<Filter>([REGION]=150)</Filter>
|
||||||
|
<!-- requires at least Mapnik 0.7.1 to work due to http://trac.mapnik.org/ticket/508 -->
|
||||||
|
<PolygonPatternSymbolizer file="../images/dummy.png" />
|
||||||
|
</Rule>
|
||||||
|
<Rule title="americas">
|
||||||
|
<Filter>([REGION]=19)</Filter>
|
||||||
|
<!-- requires at least Mapnik 0.7.1 to work due to http://trac.mapnik.org/ticket/508 -->
|
||||||
|
<LinePatternSymbolizer file="../images/dummy.png" />
|
||||||
|
</Rule>
|
||||||
|
<Rule title="Africa">
|
||||||
|
<Filter>([REGION]=2)</Filter>
|
||||||
|
<ShieldSymbolizer name="NAME" placement="vertex" face_name="DejaVu Sans Bold" size="10" fill="#000000" file="../images/dummy.png" />
|
||||||
|
</Rule>
|
||||||
|
|
||||||
|
<Rule title="rest">
|
||||||
|
<ElseFilter />
|
||||||
|
<LineSymbolizer>
|
||||||
|
<CssParameter name="stroke-width">.1</CssParameter>
|
||||||
|
</LineSymbolizer>
|
||||||
|
</Rule>
|
||||||
|
</Style>
|
||||||
|
|
||||||
|
<Layer name="world_merc">
|
||||||
|
<StyleName>test</StyleName>
|
||||||
|
<Datasource>
|
||||||
|
<Parameter name="file">../../data/shp/world_merc</Parameter>
|
||||||
|
<Parameter name="type">shape</Parameter>
|
||||||
|
</Datasource>
|
||||||
|
</Layer>
|
||||||
|
</Map>
|
Loading…
Reference in a new issue