source: subversion/applications/rendering/toposm/labels-nohalo.xml.templ @ 27489

Last change on this file since 27489 was 24303, checked in by ahlzen, 9 years ago

Fixed symbols dir reference in style definitions.

File size: 10.5 KB
Line 
1<?xml version="1.0" encoding="utf-8"?>
2<!DOCTYPE Map[
3    <!ENTITY % utils SYSTEM "include/utils.inc">
4    <!ENTITY % colors SYSTEM "include/colors.inc">
5        <!ENTITY dbsettings SYSTEM "include/dbsettings.inc">
6        <!ENTITY extents SYSTEM "include/extents.inc">
7       
8        <!ENTITY symbolsdir "symbols">
9        <!ENTITY customsymbolsdir "custom-symbols">
10        %utils;
11        %colors;
12]>
13
14<!-- NOTE: symbols that need to go on top of road fills are
15considered "labels-nohalo" as well... -->
16
17<Map bgcolor="&landcolor;" srs="&srs900913;">
18
19<Style name="interstateshields">
20        <Rule>
21      &minz6;
22      <ShieldSymbolizer name="roadnumber" face_name="DejaVu Sans Bold" size="10"
23        fill="white" placement="line"
24        file="&customsymbolsdir;/shield-interstate.png"
25        type="png" width="22" height="21"
26        min_distance="50" spacing="1000" />
27    </Rule>
28</Style>
29
30<Style name="usshields">
31        <Rule>
32      &minz9;
33      <Filter>[highway] = 'motorway' or [highway] = 'trunk'</Filter>
34      <ShieldSymbolizer name="roadnumber" face_name="DejaVu Sans Bold" size="10"
35        fill="black" placement="line"
36        file="&customsymbolsdir;/shield-us-3.png"
37        type="png" width="22" height="18"
38        min_distance="45" spacing="750" />
39    </Rule>
40        <Rule>
41      &minz11;
42      <Filter>[highway] &lt;&gt; 'motorway' and [highway] &lt;&gt; 'trunk'</Filter>
43      <ShieldSymbolizer name="roadnumber" face_name="DejaVu Sans Bold" size="10"
44        fill="black" placement="line"
45        file="&customsymbolsdir;/shield-us-3.png"
46        type="png" width="22" height="18"
47        min_distance="45" spacing="750" />
48    </Rule>
49</Style>
50
51<Style name="stateshields">
52    <Rule>
53      &minz9;
54      <Filter>[highway] = 'motorway' or [highway] = 'trunk'</Filter>
55      <ShieldSymbolizer name="roadnumber" face_name="DejaVu Sans Book" size="9"
56        fill="black" placement="line"
57        file="&customsymbolsdir;/shield-ma-3.png"
58        type="png" width="21" height="16"
59        min_distance="45" spacing="750" />
60    </Rule>
61        <Rule>
62      &minz12;
63      <Filter>[highway] &lt;&gt; 'motorway' and [highway] &lt;&gt; 'trunk'</Filter>
64      <ShieldSymbolizer name="roadnumber" face_name="DejaVu Sans Book" size="9"
65        fill="black" placement="line"
66        file="&customsymbolsdir;/shield-ma-3.png"
67        type="png" width="21" height="16"
68        min_distance="45" spacing="750" />
69    </Rule>
70</Style>
71
72<Style name="symbols">
73
74        <!-- airports -->
75        <Rule>
76        &minz12;
77        &maxz13;
78        <Filter>[aeroway] = 'aerodrome'</Filter>
79        <PointSymbolizer file="&customsymbolsdir;/black-xs/airport.png" type="png" width="11" height="11" />
80    </Rule>
81        <Rule>
82        &minz14;
83        &maxz14;
84        <Filter>[aeroway] = 'aerodrome'</Filter>
85        <PointSymbolizer file="&customsymbolsdir;/black-s/airport.png" type="png" width="14" height="14" />
86    </Rule>
87        <Rule>
88                &minz15;
89        <Filter>[aeroway] = 'aerodrome'</Filter>
90        <PointSymbolizer file="&customsymbolsdir;/black-m/airport.png" type="png" width="17" height="17" />
91        </Rule>
92       
93        <!-- rail stations, other stations -->
94    <Rule>
95        &minz14;
96        &maxz14;
97        <Filter>
98                [railway] = 'station' or
99                [railway] = 'halt' or
100                [railway] = 'tram_station' or
101                [aerialway] = 'station'
102        </Filter>
103        <PointSymbolizer file="&customsymbolsdir;/rail-station-s.png" type="png" width="6" height="6" />
104    </Rule>
105    <Rule>
106        &minz15;
107        <Filter>
108                [railway] = 'station' or
109                [railway] = 'halt' or
110                [railway] = 'tram_station' or
111                [aerialway] = 'station'
112        </Filter>
113        <PointSymbolizer file="&customsymbolsdir;/rail-station-m.png" type="png" width="10" height="10" />
114    </Rule>
115
116        <!-- mountain huts -->
117        <Rule>
118        &minz13;
119        &maxz13;
120        <Filter>[tourism] = 'alpine_hut'</Filter>
121        <PointSymbolizer file="&customsymbolsdir;/black-xs/hut.png" type="png" width="11" height="11" />
122    </Rule>
123        <Rule>
124        &minz14;
125        &maxz14;
126        <Filter>[tourism] = 'alpine_hut'</Filter>
127        <PointSymbolizer file="&customsymbolsdir;/black-s/hut.png" type="png" width="14" height="14" />
128    </Rule>
129        <Rule>
130                &minz15;
131                <Filter>[tourism] = 'alpine_hut'</Filter>
132        <PointSymbolizer file="&customsymbolsdir;/black-m/hut.png" type="png" width="17" height="17" />
133        </Rule>
134
135        <!-- shelters -->
136        <Rule>
137        &minz13;
138        &maxz13;
139        <Filter>[amenity] = 'shelter'</Filter>
140        <PointSymbolizer file="&customsymbolsdir;/black-xs/shelter.png" type="png" width="11" height="11" />
141    </Rule>
142        <Rule>
143        &minz14;
144        &maxz14;
145        <Filter>[amenity] = 'shelter'</Filter>
146        <PointSymbolizer file="&customsymbolsdir;/black-s/shelter.png" type="png" width="14" height="14" />
147    </Rule>
148        <Rule>
149                &minz15;
150                <Filter>[amenity] = 'shelter'</Filter>
151        <PointSymbolizer file="&customsymbolsdir;/black-m/shelter.png" type="png" width="17" height="17" />
152        </Rule>
153
154        <!-- public parking lots -->
155        <Rule>
156        &minz13;
157        &maxz13;
158        <Filter>
159            [amenity] = 'parking'
160            and [access] &lt;&gt; 'destination'
161            and [access] &lt;&gt; 'private'
162            and [access] &lt;&gt; 'no'
163        </Filter>
164        <PointSymbolizer file="&customsymbolsdir;/black-xs/parking.png" type="png" width="11" height="11" />
165    </Rule>
166        <Rule>
167        &minz14;
168        &maxz14;
169        <Filter>
170            [amenity] = 'parking'
171            and [access] &lt;&gt; 'destination'
172            and [access] &lt;&gt; 'private'
173            and [access] &lt;&gt; 'no'
174        </Filter>
175        <PointSymbolizer file="&customsymbolsdir;/black-s/parking.png" type="png" width="14" height="14" />
176    </Rule>
177        <Rule>
178                &minz15;
179                <Filter>
180                    [amenity] = 'parking'
181            and [access] &lt;&gt; 'destination'
182            and [access] &lt;&gt; 'private'
183            and [access] &lt;&gt; 'no'
184                </Filter>
185        <PointSymbolizer file="&customsymbolsdir;/black-m/parking.png" type="png" width="17" height="17" />
186        </Rule>
187       
188        <!-- viewpoints -->
189        <Rule>
190        &minz13;
191        &maxz13;
192        <Filter>[tourism] = 'viewpoint'</Filter>
193        <PointSymbolizer file="&customsymbolsdir;/black-xs/view.png" type="png" width="11" height="11" />
194    </Rule>
195        <Rule>
196        &minz14;
197        &maxz14;
198        <Filter>[tourism] = 'viewpoint'</Filter>
199        <PointSymbolizer file="&customsymbolsdir;/black-s/view.png" type="png" width="14" height="14" />
200    </Rule>
201        <Rule>
202                &minz15;
203                <Filter>[tourism] = 'viewpoint'</Filter>
204        <PointSymbolizer file="&customsymbolsdir;/black-m/view.png" type="png" width="17" height="17" />
205        </Rule>
206
207        <!-- public restrooms -->
208        <Rule>
209        &minz14;
210        &maxz14;
211        <Filter>[amenity] = 'toilets' or [amenity] = 'restrooms'</Filter>
212        <PointSymbolizer file="&customsymbolsdir;/black-s/restrooms.png" type="png" width="14" height="14" />
213    </Rule>
214        <Rule>
215                &minz15;
216                <Filter>[amenity] = 'toilets' or [amenity] = 'restrooms'</Filter>
217        <PointSymbolizer file="&customsymbolsdir;/black-m/restrooms.png" type="png" width="17" height="17" />
218        </Rule>
219       
220        <!-- campgrounds -->
221        <Rule>
222        &minz14;
223        &maxz14;
224        <Filter>[tourism] = 'camp_site'</Filter>
225        <PointSymbolizer file="&customsymbolsdir;/black-s/campground.png" type="png" width="14" height="14" />
226    </Rule>
227        <Rule>
228                &minz15;
229                <Filter>[tourism] = 'camp_site'</Filter>
230        <PointSymbolizer file="&customsymbolsdir;/black-m/campground.png" type="png" width="17" height="17" />
231        </Rule>
232       
233        <!-- information -->
234        <Rule>
235        &minz14;
236        &maxz14;
237        <Filter>[tourism] = 'information'</Filter>
238        <PointSymbolizer file="&customsymbolsdir;/black-s/info.png" type="png" width="14" height="14" />
239    </Rule>
240        <Rule>
241                &minz15;
242                <Filter>[tourism] = 'information'</Filter>
243        <PointSymbolizer file="&customsymbolsdir;/black-m/info.png" type="png" width="17" height="17" />
244        </Rule>
245       
246        <!-- drinking water -->
247        <Rule>
248        &minz14;
249        &maxz14;
250        <Filter>[amenity] = 'drinking_water'</Filter>
251        <PointSymbolizer file="&customsymbolsdir;/black-s/water.png" type="png" width="14" height="14" />
252    </Rule>
253        <Rule>
254                &minz15;
255                <Filter>[amenity] = 'drinking_water'</Filter>
256        <PointSymbolizer file="&customsymbolsdir;/black-m/water.png" type="png" width="17" height="17" />
257        </Rule>
258       
259        <!-- picnic sites -->
260        <Rule>
261        &minz14;
262        &maxz14;
263        <Filter>[tourism] = 'picnic_site'</Filter>
264        <PointSymbolizer file="&customsymbolsdir;/black-s/picnic-area.png" type="png" width="14" height="14" />
265    </Rule>
266        <Rule>
267                &minz15;
268                <Filter>[tourism] = 'picnic_site'</Filter>
269        <PointSymbolizer file="&customsymbolsdir;/black-m/picnic-area.png" type="png" width="17" height="17" />
270        </Rule>
271   
272    <!-- restaurants -->
273        <Rule>
274                &minz15;
275                <Filter>
276                        [amenity] = 'restaurant' or
277                        [amenity] = 'fast_food' or
278                        [amenity] = 'food_court'
279                </Filter>
280        <PointSymbolizer file="&customsymbolsdir;/black-m/food.png" type="png" width="17" height="17" />
281        </Rule>
282       
283        <!-- mines etc (tagged 'quarry' from the GNIS import) -->
284        <!--
285    <Rule>
286        &minz14;
287        &maxz14;
288        <Filter>[landuse] = 'quarry'</Filter>
289        <PointSymbolizer file="&customsymbolsdir;/black-s/mine.png" type="png" width="14" height="14" />
290    </Rule>
291    -->
292    <Rule>
293        &minz15;
294        <Filter>[landuse] = 'quarry'</Filter>
295        <PointSymbolizer file="&customsymbolsdir;/black-m/mine.png" type="png" width="17" height="17" />
296    </Rule>
297</Style>
298
299
300<!-- Layers -->
301
302
303<!-- NOTE: symbols may be needed for both point and area objects -->
304
305<Layer name="point-symbols" status="on">
306    <StyleName>symbols</StyleName>
307    <Datasource>
308      &dbsettings;
309      &extents;
310      <Parameter name="table">${DB_PREFIX}_point</Parameter>
311    </Datasource>
312</Layer>
313
314<!--
315<Layer name="area-symbols" status="on">
316    <StyleName>symbols</StyleName>
317    <Datasource>
318      &dbsettings;
319      &extents;
320      <Parameter name="table">${DB_PREFIX}_area</Parameter>
321    </Datasource>
322</Layer>
323-->
324
325
326<Layer name="interstateshields" status="on">
327    <StyleName>interstateshields</StyleName>
328    <Datasource>
329        &dbsettings;
330        &extents;               
331                <Parameter name="table">
332                (select * from ${DB_PREFIX}_roads
333                where (highway = 'motorway' or highway = 'trunk') and roadtype = 'I'
334                order by z_order) as interstateshields
335                </Parameter>
336    </Datasource>
337</Layer>
338
339<Layer name="usshields" status="on">
340    <StyleName>usshields</StyleName>
341    <Datasource>
342                &dbsettings;
343                &extents;               
344                <Parameter name="table">
345                (select * from ${DB_PREFIX}_roads
346                where (highway &lt;&gt; '' AND highway IS NOT NULL) and roadtype = 'U'
347                order by z_order) as usshields
348                </Parameter>
349    </Datasource>
350</Layer>
351
352<Layer name="stateshields" status="on">
353    <StyleName>stateshields</StyleName>
354    <Datasource>
355        &dbsettings;
356        &extents;
357                <Parameter name="table">
358                (select * from ${DB_PREFIX}_roads
359                where (highway &lt;&gt; '' AND highway IS NOT NULL) and roadtype = 'S'
360                order by z_order) as stateshields
361                </Parameter>
362    </Datasource>
363</Layer>
364
365</Map>
Note: See TracBrowser for help on using the repository browser.