Depending on the scale we choose for our map, we might want more or less information shown. Additionally, we might create a style that we want to reuse for other maps with different scales and extents.
Proposal:
The direct children of <layers> can be either layer types or the <scale> element. The <scale> element must have one or both of largest and smallest properties which represent the minimum and/or maximum scale at which the layer types within the <scale> element will be rendered. Note that the value of largest will actually be less than smallest because a large scale means "zoomed out":
<layers>
<!-- Always rendered. -->
<polyline ref="park" fill="#082d17"/>
<!-- Only rendered if scale is more zoomed out than 1:10000 -->
<scale smallest="10000">
<polyline ref="highway" stroke="#2518ba" thickness="2"/>
</scale>
<!-- Only rendered if scale is between 1:1000 and 1:5000 -->
<scale largest="1000" smallest="5000">
<nodeshape ref="memorial" fill="#828c38" angle="0" radius="1" vertices="4"/>
</scale>
</layers>
Depending on the scale we choose for our map, we might want more or less information shown. Additionally, we might create a style that we want to reuse for other maps with different scales and extents.
Proposal:
The direct children of
<layers>can be either layer types or the<scale>element. The<scale>element must have one or both oflargestandsmallestproperties which represent the minimum and/or maximum scale at which the layer types within the<scale>element will be rendered. Note that the value oflargestwill actually be less thansmallestbecause a large scale means "zoomed out":