Menu

CoordValue

Agnar Renolen

CoordValue

Provides a place holder for coordinate values. It is designed only to display parts of coordinate values.

Note that the final string will be trimmed for leading and trailing spaces before added to the map frame.

Attributes

unit

Specifies the coordinate unit to display. For projected map coordinates, the following values are legal (In parenthesis the result is given for the coordinate 87654321W).

  • m (87654321)
  • km (87654)
  • 10km (8765)
  • 100km (876)
  • 1000km (87)
  • sign (-)
  • news (W)

Comment: Also need to introduce feet conversions here for the American audience. But as of now, not supported.

For graticule, the following values are legal (In parenthesis the result is given for the coordinate "123:45:00W")

  • deg (123)
  • min (45)
  • sec (67)
  • ddeg - decimal degrees (123.75)
  • dmin - decimal minutes (45.0)
  • dsec - decimal seconds (0.0)
  • sign (-)
  • news (W)

NOTE: In order to use the graticule values, a spatial reference system (srs) must be specified for the map frame.

width

Specifies the number of digits to display. For example, for the coordinate 87654321W <CoordValue type="km" width=2 /> would insert the value "54".

zero-padding

If yes (default) will pad with zeroes, if there are not enough digits to fill the entire width. For example for the coordinate 4321W <CoordValue type="km" width=2 padding="yes" />
would insert the value "04". If omitted wold only insert the value 4.

decimals

Only applicable if unit is ddeg, dmin or dsec. Specifies the number of decimals to display in the
coordinate.

NOTE: Make sure that the width attribute is big enough to hold the decimals and the decimal separator.

smaller

If specified gives the relative font size in fractions. That is, if the value is "60%" the text size will be reduced with 60% but on the same base line.

rised

If specified, specified that the text size is to be reduced by a certain fraction. Similar to smaller, but raises the text to keep the text aligned with the ascent line.

Example

The following sample will display a classic longitude coordinate:

<RulerLabels interval="10min">
   <CoordValue unit="deg" width="3" padding="yes"/>&#xb0;<CoordValue unit="min" />&apos;<CoordValue unit="sec" />&quot;<CoordValue unit="news" />
</RulerLabels>

The following sample will display a typical UTM coordinate value.

<RulerLabels interval="1km">
   <CoordValue unit="100km" rised="50%" /><CoordValue unit="km" width="2" />
</RulerLabels>

Related

Wiki: RulerLabels

MongoDB Logo MongoDB