Documentation of 'org.opengis.go.display.primitive.GraphicLabel' Java class
GraphicLabel
org.opengis.go.display.primitive

Interface GraphicLabel

  • All Superinterfaces:
    Graphic


    public interface GraphicLabel
    extends Graphic
    Defines a common abstraction for implementations that render text on a drawing surface. The rotation of the label with respect to an external Coordinate Reference System is measured positively as a clockwise angle, starting from a reference line within the Coordinate Reference System and ending at the x-axis of the local Cartesian plane.
    • Method Detail

      • setText

        void setText(java.lang.String text)
        Sets the text that the label will render.
        Parameters:
        text - the text to display.
      • getText

        java.lang.String getText()
        Returns the text that will be displayed.
        Returns:
        the text to be rendered.
      • setPosition

        void setPosition(DirectPosition coord)
        Sets the position of the upper left corner of the label.
        Parameters:
        coord - the wrapper for the position of the label.
      • getPosition

        DirectPosition getPosition()
        Returns the DirectPosition corresponding to the position of the label.
        Returns:
        the wrapper for the position.
      • setXAnchor

        void setXAnchor(XAnchor xAnchor)
        Specifies the x-axis portion of the place on the text string that corresponds to the rendering position (see the [gs]etPosition method).
        Parameters:
        xAnchor - the x-axis location on the string (i.e., left, center, right).
      • getXAnchor

        XAnchor getXAnchor()
        Returns the x-axis portion of the place on the text string that corresponds to the rendering position (see the [gs]etPosition method).
        Returns:
        the x-axis portion of the text anchor point.
      • setYAnchor

        void setYAnchor(YAnchor yAnchor)
        Specifies the y-axis portion of the place on the text string that corresponds to the rendering position (see the [gs]etPosition method).
        Parameters:
        yAnchor - the y-axis location on the string (i.e., top, middle, baseline, bottom).
      • getYAnchor

        YAnchor getYAnchor()
        Returns the y-axis portion of the place on the text string that corresponds to the rendering position (see the [gs]etPosition method).
        Returns:
        the y-axis portion of the text anchor point.
      • setRotation

        void setRotation(double rotation,
                         Unit unit)
        Sets the angle by which to rotate the text before rendering. The text is rotated about its anchor (see the set[XY]Anchor methods).
        Parameters:
        rotation - the new rotation.
        unit - the Unit for the angle value.
      • getRotation

        double getRotation(Unit unit)
        Returns the orientation by which to rotate the text before rendering.
        Parameters:
        unit - the Unit for the angle value.
        Returns:
        the rotation orientation.
      • getTextSymbolizer

        TextSymbolizer getTextSymbolizer()
        Returns the GraphicStyle for this GraphicLabel, which is required to be a TextSymbolizer.
        Returns:
        the GraphicLabel's GraphicStyle.
      • isAllowingRotation

        boolean isAllowingRotation()
        Indicates whether this primitive is displaying anchor handles that allow the user to change the rotation of the text.
      • setAllowingRotation

        void setAllowingRotation(boolean newValue)
        Sets the boolean that indicates whether this primitive is displaying anchor handles that allow the user to change the rotation of the text.

DataMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.