Class MarkStyle2D

    • Constructor Detail

      • MarkStyle2D

        public MarkStyle2D()
    • Method Detail

      • getRotation

        public float getRotation()
        Returns the shape rotation, in radians
        Specified by:
        getRotation in interface PointStyle2D
        Returns:
        shape rotation, in radians
      • getShape

        public Shape getShape()
        Returns the shape to be used to render the mark
      • getTransformedShape

        public Shape getTransformedShape​(float x,
                                         float y)
        Returns a shape that can be used to draw the mark at the x, y coordinates with appropriated rotation and size (according to the current style)
        Parameters:
        x - the x coordinate where the mark will be drawn
        y - the y coordinate where the mark will be drawn
        Returns:
        a shape that can be used to draw the mark
      • getTransformedShape

        public Shape getTransformedShape​(float x,
                                         float y,
                                         float baseRotation,
                                         float rotation)
        Returns a shape that can be used to draw the mark at the x, y coordinates with appropriated rotation and size (according to the current style)
        Parameters:
        x - the x coordinate where the mark will be drawn
        y - the y coordinate where the mark will be drawn
        baseRotation - a custom rotation that will be applied before offsets
        rotation - the mark rotation
        Returns:
        a shape that can be used to draw the mark
      • getSize

        public double getSize()
        Returns the size of the shape, in pixels
      • setRotation

        public void setRotation​(float f)
        Sets the shape rotation, in radians
        Specified by:
        setRotation in interface PointStyle2D
      • setShape

        public void setShape​(Shape shape)
        Sets the shape to be used to render the mark
      • setSize

        public void setSize​(double i)
        Sets the size of the shape, in pixels
      • isMaxMarkSizeEnabled

        public static boolean isMaxMarkSizeEnabled()
      • setMaxMarkSizeEnabled

        public static void setMaxMarkSizeEnabled​(boolean useMaxMarkSize)
        When true makes the mark scale itself to size using the max between the original width and height, otherwise it defaults to the mark height (which has been the original behavior of this class)
        Since:
        2.7.3
      • setDisplacementX

        public void setDisplacementX​(float displacementX)
        Description copied from interface: PointStyle2D
        Sets the point symbol x displacement
        Specified by:
        setDisplacementX in interface PointStyle2D
      • setDisplacementY

        public void setDisplacementY​(float displacementY)
        Description copied from interface: PointStyle2D
        Sets the point symbol y displacement
        Specified by:
        setDisplacementY in interface PointStyle2D
      • getAnchorPointX

        public float getAnchorPointX()
        Description copied from interface: PointStyle2D
        The point symbol x anchor, between 0 and 1, defaults to 0.5
        Specified by:
        getAnchorPointX in interface PointStyle2D
      • setAnchorPointX

        public void setAnchorPointX​(float anchorPointX)
        Description copied from interface: PointStyle2D
        Sets the point symbol x anchor, between 0 and 1
        Specified by:
        setAnchorPointX in interface PointStyle2D
      • getAnchorPointY

        public float getAnchorPointY()
        Description copied from interface: PointStyle2D
        The point symbol y anchor, between 0 and 1, defaults to 0.5
        Specified by:
        getAnchorPointY in interface PointStyle2D
      • setAnchorPointY

        public void setAnchorPointY​(float anchorPointY)
        Description copied from interface: PointStyle2D
        Sets the point symbol y anchor, between 0 and 1
        Specified by:
        setAnchorPointY in interface PointStyle2D