[mapserver-users] Label not Displaying at Edge of Map Extent

Fawcett, David (MNIT) David.Fawcett at state.mn.us
Wed Feb 24 06:09:53 PST 2016


Michele,

I am guessing that if you set LABEL PARTIALS to TRUE (or just comment it out), you will see your label.

http://mapserver.org/mapfile/label.html

David.

From: mapserver-users [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Michele Toma
Sent: Tuesday, February 23, 2016 7:14 PM
To: mapserver-users at lists.osgeo.org
Subject: [mapserver-users] Label not Displaying at Edge of Map Extent

Hi everyone,

I am having an issue with getting a label to display when it is near the edge of the map extent. From what I have seen, when I attach the style for the icon to the label object, the label does not display. However, if I remove the style for the icon from the label object, it does display. Is this an issue with MapServer 7 or the settings that I have used?

Version Information:
[root at Map18-03 cgi-bin]# ./mapserv -v
MapServer version 7.0.0 OUTPUT=PNG OUTPUT=JPEG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICONV SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=FASTCGI SUPPORTS=GEOS INPUT=JPEG INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE

Below is the map file to reproduce the issue. Please note that there are two layers - one without the icon style attached, and one with the icon style attached. The layer without the icon style attached has been turned on while the other is off.

==============================

MAP

  EXTENT -87.919802 0.000000 72.177555 90.000000
  SIZE 1280 720
  IMAGECOLOR 140 140 140

  SYMBOL
    NAME 'Airport'
    TYPE ELLIPSE
    POINTS 1 1 END
    FILLED true
  END

  LAYER
    NAME "Label does display (no icon)"
    TYPE POINT
    FEATURE
        POINTS
          -87.9 41.983333
        END
    END
    PROJECTION
      "proj=latlong"
      "ellps=WGS84"
    END # PROJECTION
    STATUS DEFAULT
    CLASS
      TEXT 'Label'
      LABEL
        TYPE BITMAP
        SIZE 20
        COLOR 255 255 255
        PARTIALS FALSE
        POSITION AUTO
        PRIORITY 10
      END # LABEL
    END # CLASS
  END # LAYER


  LAYER
    NAME "Label does not display (with icon)"
    TYPE POINT
    FEATURE
        POINTS
          -87.9 41.983333
        END
    END
    PROJECTION
      "proj=latlong"
      "ellps=WGS84"
    END # PROJECTION
    STATUS OFF
    CLASS
      TEXT 'Label'
      LABEL
        TYPE BITMAP
        SIZE 20
        COLOR 255 255 255
        PARTIALS FALSE
        POSITION AUTO
        PRIORITY 10
        STYLE
          SYMBOL "Airport"
          COLOR 0 255 0
          OUTLINECOLOR 0 0 0
          SIZE 20
        END # STYLE
      END # LABEL
    END # CLASS
  END # LAYER

END

Thank you,

Michele Toma
michele.toma at airborne.aero<mailto:michele.toma at airborne.aero>
www.airborne.aero

[New Small2]

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20160224/129c4435/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.jpg
Type: image/jpeg
Size: 2598 bytes
Desc: image001.jpg
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20160224/129c4435/attachment-0001.jpg>


More information about the mapserver-users mailing list