[mapserver-users] symbology showing line direction

G. Allegri giohappy at gmail.com
Fri Feb 29 10:53:20 EST 2008


About GAP: http://mapserver.gis.umn.edu/docs/reference/symbology/referencemanual-all-pages

2008/2/29, G. Allegri <giohappy at gmail.com>:
> Adam, you gave me a little doubt abotu shp line directions and Mapserver...
>
>  Could you try to use a simble like this?
>
>  SYMBOL
>
>     NAME "arrow"
>     TYPE TRUETYPE
>     FONT verdana
>     CHARACTER '&\#62;' # don't use the backslash! (the verdana greater
>  than tag)
>     FILLED true
>     ANTIALIAS true
>     GAP -10 # the negatation tells MapServer to honor the vector
>  direction when computing the angle
>
>  END
>
>  and use it in the STYLE of the layer CLASS
>
>  Put attention on the GAP parameter
>
>
>  2008/2/29, Adam Feidt <afeidt at edenprairie.org>:
>  > I was hoping it could read ESRI's From and To node structure much like
>  >  ArcMap, but by the sounds of it that isn't possible. Shapefile geometry
>  >  is saved in the Shape column, which I'm guessing is useless in
>  >  Mapserver.  What you're saying is I need to create an attribute and
>  >  populate it with the angle of the line and use that to define my label
>  >  direction?
>  >
>  >
>  >  Adam M. Feidt
>  >  GIS Coordinator
>  >  City of Eden Prairie
>  >  8080 Mitchell Rd
>  >  Eden Prairie, MN 55344
>  >  phone# 952-949-8443
>  >  fax# 952-949-8334
>  >
>  >
>  >
>  > -----Original Message-----
>  >  From: G. Allegri [mailto:giohappy at gmail.com]
>  >  Sent: Friday, February 29, 2008 8:57 AM
>  >  To: Adam Feidt
>  >  Cc: Fawcett, David; mapserver-users at lists.osgeo.org
>  >  Subject: Re: [mapserver-users] symbology showing line direction
>  >
>  >  A question: how can you derive a line direction by a shp without
>  >  having an appropriate attribute?
>  >
>  >  Giovanni
>  >
>  >  2008/2/29, Adam Feidt <afeidt at edenprairie.org>:
>  >  >
>  >  >
>  >  >
>  >  >
>  >  > David,
>  >  >
>  >  >      Below is my Layer definition.  I've tried a truetype symbol and
>  >  label
>  >  > with the ANGLE parameter set to AUTO or FOLLOW.  Neither case pointed
>  >  out
>  >  > actual shapefile line direction.  I'm reading an ESRI shapefile so
>  >  there is
>  >  > no specific column for line direction.
>  >  >
>  >  >
>  >  >
>  >  > LAYER
>  >  >
>  >  >             NAME 'Utilities Sanitary Lines'
>  >  >
>  >  >             DATA './UtilitiesSanitaryLines.shp'
>  >  >
>  >  >             TYPE LINE
>  >  >
>  >  >             STATUS DEFAULT
>  >  >
>  >  >             CLASSITEM "Function"
>  >  >
>  >  >             CLASS
>  >  >
>  >  >                   NAME 'Main'
>  >  >
>  >  >                   EXPRESSION ""
>  >  >
>  >  >                   STYLE
>  >  >
>  >  >                     COLOR 85 255 0
>  >  >
>  >  >                     SYMBOL "plainline"
>  >  >
>  >  >                     SIZE 2
>  >  >
>  >  >                   END
>  >  >
>  >  >             END # end class
>  >  >
>  >  >             CLASS
>  >  >
>  >  >                   NAME 'Low Pressure'
>  >  >
>  >  >                   EXPRESSION "Low Pressure"
>  >  >
>  >  >                   STYLE
>  >  >
>  >  >                     COLOR 255 85 0
>  >  >
>  >  >                     SYMBOL "plainline"
>  >  >
>  >  >                     SIZE 2
>  >  >
>  >  >                   END
>  >  >
>  >  >             END # end class
>  >  >
>  >  >             CLASS
>  >  >
>  >  >                   NAME 'Sub Trunk'
>  >  >
>  >  >                   EXPRESSION "Sub Trunk"
>  >  >
>  >  >                   STYLE
>  >  >
>  >  >                     COLOR 85 255 0
>  >  >
>  >  >                     SYMBOL "plainline"
>  >  >
>  >  >                     SIZE 2
>  >  >
>  >  >                   END
>  >  >
>  >  >             END # end class
>  >  >
>  >  >             CLASS
>  >  >
>  >  >                   NAME 'Trunk'
>  >  >
>  >  >                   EXPRESSION "Trunk"
>  >  >
>  >  >                   STYLE
>  >  >
>  >  >                     COLOR 112 168 0
>  >  >
>  >  >                     SYMBOL "plainline"
>  >  >
>  >  >                     SIZE 2
>  >  >
>  >  >                   END
>  >  >
>  >  >             END # end class
>  >  >
>  >  >             CLASS
>  >  >
>  >  >                   NAME 'Force Main'
>  >  >
>  >  >                   EXPRESSION "forcemain"
>  >  >
>  >  >                   STYLE
>  >  >
>  >  >                     COLOR 255 170 0
>  >  >
>  >  >                     SYMBOL 'dashed1'
>  >  >
>  >  >                     SIZE 2
>  >  >
>  >  >                   END
>  >  >
>  >  >             END # end class
>  >  >
>  >  >             CLASS
>  >  >
>  >  >                   NAME 'Private'
>  >  >
>  >  >                   EXPRESSION "private"
>  >  >
>  >  >                   STYLE
>  >  >
>  >  >                     COLOR 161 33 240
>  >  >
>  >  >                     SYMBOL 'plainline'
>  >  >
>  >  >                     SIZE 2
>  >  >
>  >  >                   END
>  >  >
>  >  >             END # end class
>  >  >
>  >  >       END #end layer
>  >  >
>  >  >
>  >  >
>  >  >
>  >  >
>  >  >
>  >  > Adam M. Feidt
>  >  >
>  >  > GIS Coordinator
>  >  >
>  >  > City of Eden Prairie
>  >  >
>  >  > 8080 Mitchell Rd
>  >  >
>  >  > Eden Prairie, MN 55344
>  >  >
>  >  > phone# 952-949-8443
>  >  >
>  >  > fax# 952-949-8334
>  >  >
>  >  >
>  >  >
>  >  >
>  >  >
>  >  > From: Fawcett, David [mailto:David.Fawcett at state.mn.us]
>  >  >  Sent: Friday, February 29, 2008 8:19 AM
>  >  >  To: Adam Feidt; mapserver-users at lists.osgeo.org
>  >  >  Subject: RE: [mapserver-users] symbology showing line direction
>  >  >
>  >  >
>  >  >
>  >  >
>  >  >
>  >  > Adam,
>  >  >
>  >  >
>  >  >
>  >  >
>  >  >
>  >  > What does your layer definition, with the classes look like?
>  >  >
>  >  >
>  >  >
>  >  >
>  >  >
>  >  > Does your data have the direction column properly populated for all
>  >  records?
>  >  >
>  >  >
>  >  >
>  >  >
>  >  >
>  >  >
>  >  > David.
>  >  >
>  >  >
>  >  > -----Original Message-----
>  >  >  From: mapserver-users-bounces at lists.osgeo.org
>  >  > [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf
>  >  > Of Adam Feidt
>  >  >  Sent: Friday, February 29, 2008 8:14 AM
>  >  >  To: mapserver-users at lists.osgeo.org
>  >  >  Subject: [mapserver-users] symbology showing line direction
>  >  >
>  >  >       I'm working in a GeoMoose application and trying to display
>  >  utility
>  >  > lines with the correct line direction via some arrow character or
>  >  symbol.
>  >  > I've had no luck so far.  I've successfully labeled my lines with a
>  >  truetype
>  >  > font character by defining the TEXT ">" parameter in the CLASS object.
>  >  I've
>  >  > also tried a pixelmap symbol definition using a .gif file.  Both
>  >  appear to
>  >  > work at first, but when you compare it to the actual line direction it
>  >  isn't
>  >  > true in all cases.  Has anybody found a way to accomplish this?  I
>  >  would
>  >  > appreciate if you could send me any examples.
>  >  >
>  >  >
>  >  >
>  >  >
>  >  >
>  >  > Adam M. Feidt
>  >  >
>  >  > GIS Coordinator
>  >  >
>  >  > City of Eden Prairie
>  >  >
>  >  > 8080 Mitchell Rd
>  >  >
>  >  > Eden Prairie, MN 55344
>  >  >
>  >  > phone# 952-949-8443
>  >  >
>  >  > fax# 952-949-8334
>  >  >
>  >  >
>  >  > _______________________________________________
>  >  >  mapserver-users mailing list
>  >  >  mapserver-users at lists.osgeo.org
>  >  >  http://lists.osgeo.org/mailman/listinfo/mapserver-users
>  >  >
>  >  >
>  >
>  >
>


More information about the mapserver-users mailing list