[mapserver-dev] GEOMTRANSFORM labelpnt location

Lime, Steve D (DNR) steve.lime at state.mn.us
Fri May 27 13:18:30 EDT 2011


Let me ponder this and get back to you. I think it makes sense to use the label point geotransform only with position CC so that it matches actual shape location. This particular feature is new functionality and the use case that inspired it was labeling roads with shields.

Steve

From: mapserver-dev-bounces at lists.osgeo.org [mailto:mapserver-dev-bounces at lists.osgeo.org] On Behalf Of Brent Fraser
Sent: Thursday, May 26, 2011 12:59 PM
To: Mapserver Dev
Subject: [mapserver-dev] GEOMTRANSFORM labelpnt location

Should we change the documentation on STYLE -> GEOMTRANSFORM -> labelpnt:

 *   labelpnt generates a point with its center at the middle of the bounding rectangle of the text.

or is the position generated a bug (or am I using it incorrectly)?  Have a look at the blue dot in the attached image.


    CLASS # Mountain
      NAME 'Mountain'
      EXPRESSION ([CONCISCODE]=280)
      STYLE # ------ Green Cross ------
        SYMBOL 'CROSS1'
        SIZE 8
        WIDTH 0.5
        COLOR 0 255 0
      END
      STYLE # ------ Yellow Circle ------
        GEOMTRANSFORM (labelpoint([shape]))
        SYMBOL 'CIRCLE'
        SIZE 5
        OUTLINECOLOR 255 255 0
      END
      LABEL
        STYLE # ------ Red Box ------
            GEOMTRANSFORM labelpoly
            OUTLINECOLOR 255 0 0
        END #
        STYLE #  ------ Blue Dot ------ position OK?
            GEOMTRANSFORM labelpnt
            SYMBOL 'CIRCLE'
            SIZE 2
            COLOR 0 0 255
        END #
        FONT "trebuc"
        TYPE TRUETYPE
        POSITION CC
        ALIGN CENTER
        WRAP ' '
        SIZE 6
        BUFFER 1
        COLOR 0 0 0
        ANGLE 0
        PARTIALS FALSE
        ANTIALIAS TRUE
        #MINDISTANCE 250
        #MINFEATURESIZE 10
      END
    END




--

Best Regards,

Brent Fraser
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/mapserver-dev/attachments/20110527/43eb42e9/attachment.html


More information about the mapserver-dev mailing list