label priority
Yewondwossen Assefa
assefa at DMSOLUTIONS.CA
Thu Aug 18 14:38:58 PDT 2005
Jeff,
Maybe you could sort your shape using the population attribute file
using the sortshp utility that comes with mapserver. The syntax is
something like this :
sortshp [infile] [outfile] [item] [ascending|descending]
Once sorted (I beleive descending in your case) It should draw first
the cities with the largest population.
Later,
Jeff Portwine wrote:
> I'm using a shapefile called citiesx020 to show cities in the US, and
> I'm having a small problem. In many places cities are very close
> together. I have already limited it to cities with population over a
> certain amount so I don't end up not being able to distinguish points
> but in certain cases there are sufficiently large cities that I want to
> show that are close enough together so that their labels collide. I
> have a buffer of 5 pixels, so in such cases only one of the cities will
> show their label, and the other one won't. In one particular case
> though I have New York City that is pretty close to Newark, Elizibeth,
> and Jersey City and I have the label for Elizibeth blocking the label
> for New York city. How can I give New York City precedence over the
> smaller city?
>
> I have two classes now, one that draws cities with populations over
> 500,000 and the other with populations of 100,000-499999. The bigger
> class draws bigger citiy markers and uses bold names, the smaller pop
> cities use smaller labels and markers. I've tried reversing the order
> the classes appear in the map file, but it didn't change anything... is
> there any way to accomplish this?
>
> Thanks!
> -Jeff
>
--
----------------------------------------------------------------
Assefa Yewondwossen
Software Analyst
Email: assefa at dmsolutions.ca
http://www.dmsolutions.ca/
Phone: (613) 565-5056 (ext 14)
Fax: (613) 565-0925
----------------------------------------------------------------
More information about the MapServer-users
mailing list