Class JaxoDashLoop

All Implemented Interfaces:
Shape, PropertyChangeListener, Serializable, Cloneable, EventListener
Direct Known Subclasses:
JaxoGLoop, JaxoSLoop

public abstract class JaxoDashLoop extends JaxoLoopObject
A dashed loop.
Since:
2.0
See Also:
  • Constructor Details

    • JaxoDashLoop

      public JaxoDashLoop()
  • Method Details

    • paint

      public final void paint(JaxoGraphics2D g2)
      The method that paints the JaxoObject.
      Overrides:
      paint in class JaxoLoopObject
      Parameters:
      g2 - The graphics context where the object has to be painted.
    • getBounds

      public Rectangle getBounds()
      Returns the bounding box of this object.
      Specified by:
      getBounds in interface Shape
      Overrides:
      getBounds in class JaxoLoopObject
      Returns:
      the bounding box of this object.
    • resetStroke

      protected void resetStroke()
      Resets the stroke to a default BasicStroke with current width. This should be overridden by objects that use a different stroke.
      Overrides:
      resetStroke in class JaxoExtendedObject
    • getObjectPath

      protected GeneralPath getObjectPath()
      Get the GeneralPath that paints this loop.
      Specified by:
      getObjectPath in class JaxoLoopObject
      Returns:
      GeneralPath. May be null for an object that cannot be painted.
    • getAxo4JOptions

      protected String getAxo4JOptions(float scale)
      Return the option part of the LaTeX command for this line.
      Specified by:
      getAxo4JOptions in class JaxoLoopObject
      Parameters:
      scale - the axodraw4j scale factor.
      Returns:
      the option String.
    • strokeDashes

      protected abstract float[] strokeDashes()
      Returns an array that is used as the dash parameter in BasicStroke to paint this object.
      Returns:
      a dash array.
    • innerStrokeDashes

      protected abstract float[] innerStrokeDashes(double radius)
      Returns an array that is used as the dash parameter in BasicStroke to paint the inner part of this loop in double-line mode.
      Parameters:
      radius - the radius.
      Returns:
      a dash array.
    • outerStrokeDashes

      protected abstract float[] outerStrokeDashes(double radius)
      Returns an array that is used as the dash parameter in BasicStroke to paint the outer part of this loop in double-line mode.
      Parameters:
      radius - the radius.
      Returns:
      a dash array.