[Mapserver-users] symbol without label
David Mitchell
david.mitchell at telogis.com
Thu Apr 29 14:16:31 PDT 2004
Annotation layers only draw anything when the label is displayed.
You have two choices here:
1) Change layer type to point
2) Change label text to empty string
Option 1 will mean that all the symbols will be drawn (ie, no buffering
to keep close symbols apart), but will draw regardless of whether there
is a label or not. It is a trivial change.
Option 2 would mean that when two points were really close only one
would be drawn (which is the effect you get with the annotation layer
you posted).
I assume the problem you have shows when your scale goes above 8000? Try
this for option 2 (note there are two slightly different layers here but
they show up at different scales):
> LAYER # Flurstücke
> NAME symbole
> DATA flurstuecke_region
> STATUS DEFAULT
> TYPE ANNOTATION
> LABELITEM "OBJNUM"
> MAXSCALE 8000.0
> CLASS
> EXPRESSION ('[OBJNUM]'eq '0066ZZ3' OR '[OBJNUM]'eq 'G00D8HN')
> STYLE
> SYMBOL '../symbols/sp.gif'
> END
> LABEL
> POSITION CC
> SIZE TINY
> COLOR 255 255 255
> END
> COLOR 0 0 0 END
> END # States polygon layer ends here
> LAYER # Flurstücke
> NAME symbole
> DATA flurstuecke_region
> STATUS DEFAULT
> TYPE ANNOTATION
> LABELTEXT " "
> MINSCALE 8000.0
> CLASS
> EXPRESSION ('[OBJNUM]'eq '0066ZZ3' OR '[OBJNUM]'eq 'G00D8HN')
> STYLE
> SYMBOL '../symbols/sp.gif'
> END
> LABEL
> POSITION CC
> SIZE TINY
> COLOR 255 255 255
> END
> COLOR 0 0 0 END
> END # States polygon layer ends here
Bo Nintzel wrote:
> Dear list,
> In my map I want to draw a symbol instead of the label-text.
> The position of the symbol should be the same as the annotation.
> This is a part of my Map-File:
>
> # Start of LAYER DEFINITIONS
> ---------------------------------------------
> LAYER # Flurstücke
> NAME symbole
> DATA flurstuecke_region
> STATUS DEFAULT
> TYPE ANNOTATION
> LABELITEM "OBJNUM"
> LABELMAXSCALE 8000.0
> CLASS
> EXPRESSION ('[OBJNUM]'eq '0066ZZ3' OR '[OBJNUM]'eq 'G00D8HN')
> STYLE
> SYMBOL '../symbols/sp.gif'
> END LABEL
> POSITION CC
> SIZE TINY
> COLOR 255 255 255
> END
> COLOR 0 0 0 END
> END # States polygon layer ends here
> # End of LAYER DEFINITIONS -------------------------------
>
> With this, the Label-text is drawn on top of the symbol. When I don't
> draw the Label, there is no symbol. Is there a posibility to draw the
> Symbol without the text.
>
> Regards
> Bo Nintzel
>
>
> -----------------------------
> cand. geod. Bo Nintzel
> Geodätisches Institut
> TU Darmstadt
> -----------------------------
>
> _______________________________________________
> Mapserver-users mailing list
> Mapserver-users at lists.gis.umn.edu
> http://lists.gis.umn.edu/mailman/listinfo/mapserver-users
>
>
--
David Mitchell
Software Engineer
Telogis
NOTICE:
This message (including any attachments) contains CONFIDENTIAL
INFORMATION intended for a specific individual and purpose, and
is protected by law. If you are not the intended recipient,
you should delete this message and are hereby notified that any
disclosure, copying, or distribution of this message, or the
taking of any action based on it, is strictly prohibited.
More information about the MapServer-users
mailing list