Documentation of 'jhplot.shapes.Arrow' Java class.
Arrow
jhplot.shapes

Class Arrow

  • All Implemented Interfaces:
    java.io.Serializable


    public class Arrow
    extends HShape
    Build an arrow using HPlot canvas. The default is the USER coordinate system.
    See Also:
    Serialized Form
    • Constructor Detail

      • Arrow

        public Arrow(double X1,
                     double Y1,
                     double X2,
                     double Y2,
                     java.awt.Stroke stroke,
                     java.awt.Color color)
        Build an arrow
        Parameters:
        X1 - X start position
        Y1 - Y start position
        X2 - X end position
        Y2 - Y end position
        stroke - Stroke to draw the line
        color - Color
      • Arrow

        public Arrow(double X1,
                     double Y1,
                     double X2,
                     double Y2)
        Build an arrow in
        Parameters:
        X1 - X start position
        Y1 - Y start position
        X2 - X end position
        Y2 - Y end position
    • Method Detail

      • getEndLength

        public double getEndLength()
        Get length of the ends
        Returns:
        lenght
      • getEndWidth

        public double getEndWidth()
        Get widths of the ends
        Returns:
        width
      • setEndLength

        public void setEndLength(double length)
        Set lenght of the ends
        Parameters:
        length - lenght of the ends
      • setEndWidth

        public void setEndWidth(double width)
        Set width of the ends
        Parameters:
        width - width of the ends
      • setType

        public void setType(int type)
        Set the type of arrow: 1,2,3
      • getType

        public int getType()
        Get the type of arrow
      • toString

        public java.lang.String toString()
        Represent it as a string
        Overrides:
        toString in class java.lang.Object
        Returns:
        a string representation of this HShape object
      • doc

        public void doc()
        Show online documentation.

DMelt 3.0 © DataMelt by jWork.ORG