Hide and show city labels depending on population
Milo van der Linden
mlinden at ZEELANDNET.NL
Tue Jul 10 04:05:12 PDT 2007
Hello list,
I have been puzzling a bit and am not finding the correct answer.
I have a city mapinfo tab that holds population values. I want to display:
- The labels of the major cities when zoomed out far,
- add the labels of medium cities when I zoom in further
- show all labels when zoomed in max
Currently my syntax in the mapfile is as below, but I can't get a map
that shows only the labels of the major cities!
Any help is appreciated
LABELITEM 'City'
CLASSITEM 'City_Population'
CLASS
NAME '0 < City_Population < 100000'
EXPRESSION ( ([City_Population] >= 0) AND ([City_Population] <=
100000) )
STYLE
SYMBOL 'CIRCLE'
SIZE 3
OUTLINECOLOR 0 0 0
COLOR 255 170 0
END
LABEL
TYPE TRUETYPE
FONT Arial
SIZE 8
COLOR 255 255 250
#OUTLINECOLOR 255 255 255
ANTIALIAS TRUE
MINFEATURESIZE 500
ANGLE 0
FORCE false
END
END
CLASS
NAME '100001 < City_Population < 500000'
EXPRESSION ( ([City_Population] >= 100001) AND ([City_Population]
<= 500000) )
STYLE
SYMBOL 'CIRCLE'
SIZE 4
OUTLINECOLOR 0 0 0
COLOR 255 170 0
END
LABEL
TYPE TRUETYPE
FONT Arial
SIZE 10
COLOR 255 255 250
#OUTLINECOLOR 255 255 255
ANTIALIAS TRUE
MINFEATURESIZE 500
ANGLE 0
FORCE false
END
END
--
Milo van der Linden
mlinden at zeelandnet.nl <mailto:mlinden at zeelandnet.nl>
milovanderlinden at gmail.com <mailto:milovanderlinden at gmail.com>
milo at 3dsite.nl <mailto:milo at 3dsite.nl>
http://www.3dsite.nl
De informatie in dit bericht reflecteerd mijn persoonlijke mening en
niet die van een bedrijf of instantie. Aan de informatie kunnen geen
rechten worden ontleend. Indien dit bericht onderdeel is van een forum,
mailing-list of community dan gelden automatisch de bijbehorende
voorwaarden.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20070710/c7704f3b/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 250 bytes
Desc: OpenPGP digital signature
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20070710/c7704f3b/attachment.sig>
More information about the MapServer-users
mailing list