org.opengis.style
Interface PointPlacement

All Superinterfaces:
LabelPlacement
All Known Subinterfaces:
PointPlacement
All Known Implementing Classes:
PointPlacementImpl

@XmlElement(value="PointPlacement")
public interface PointPlacement
extends LabelPlacement

A PointPlacement specifies how a text label is positioned relative to a geometric point.

Since:
GeoAPI 2.2
Author:
Open Geospatial Consortium, Johann Sorel (Geomatys), Ian Turton

Method Summary
 Object accept(StyleVisitor visitor, Object extraData)
          calls the visit method of a StyleVisitor
 AnchorPoint getAnchorPoint()
          The AnchorPoint element of a PointPlacement gives the location inside of a label to use for anchoring the label to the main-geometry point.
 Displacement getDisplacement()
          The Displacement gives the X and Y displacements from the "hot-spot" point.
 Expression getRotation()
          Returns the expression that will be used to calculate the rotation of the graphic when it is drawn.
 

Method Detail

getAnchorPoint

@XmlElement(value="PointPlacement")
AnchorPoint getAnchorPoint()
The AnchorPoint element of a PointPlacement gives the location inside of a label to use for anchoring the label to the main-geometry point. This will often be used to avoid over-plotting a graphic symbol marking a city or some such feature. The displacements are in units of pixels above and to the right of the point. A system may reflect this displacement about the X and/or Y axes to de-conflict labels. The default displacement is X=0, Y=0. See AnchorPoint for details.

Returns:
AnchorPoint : if null use X=0.5 Y=0.5

getDisplacement

@XmlElement(value="Displacement")
Displacement getDisplacement()
The Displacement gives the X and Y displacements from the "hot-spot" point. This element may be used to avoid over-plotting of multiple graphic symbols used as part of the same point symbol. The displacements are in units of measure above and to the right of the point. The default displacement is X=0, Y=0. If Displacement is used in conjunction with Size and/or Rotation then the graphic symbol shall be scaled and/or rotated before it is displaced.s

Returns:
Displacement

getRotation

@XmlElement(value="Rotation")
Expression getRotation()
Returns the expression that will be used to calculate the rotation of the graphic when it is drawn. The Rotation of a PointPlacement gives the clockwise rotation of the label in degrees from the normal direction for a font (left-to-right for Latin-derived human languages at least).

Returns:
Expression

accept

@Extension
Object accept(StyleVisitor visitor,
                        Object extraData)
calls the visit method of a StyleVisitor

Specified by:
accept in interface LabelPlacement
Parameters:
visitor - the style visitor


Copyright © 1996-2014 Geotools. All Rights Reserved.