Class AbstractPolarAxis

java.lang.Object
org.opensourcephysics.display.axes.AbstractAxes
org.opensourcephysics.display.axes.AbstractPolarAxis
All Implemented Interfaces:
DrawableAxes, PolarAxes, Drawable
Direct Known Subclasses:
PolarType1, PolarType2

public abstract class AbstractPolarAxis extends AbstractAxes implements PolarAxes
AbstractPolarAxis implements methods common to all polar axes.
Version:
1.0
Author:
Wolfgang Christian
  • Field Details

    • dr

      protected double dr
    • dtheta

      protected double dtheta
    • autospaceRings

      protected boolean autospaceRings
  • Constructor Details

    • AbstractPolarAxis

      protected AbstractPolarAxis(DrawingPanel drawingPanel)
      Creates polar axes that will display themselves within the given drawing panel.
      Parameters:
      drawingPanel - DrawingPanel
  • Method Details

    • autospaceRings

      public void autospaceRings(boolean autospace)
      Automatically sets the spacing of the radial grid.
      Specified by:
      autospaceRings in interface PolarAxes
      Parameters:
      autoscaleR -
    • getDeltaR

      public double getDeltaR()
      Gets the spacing of the radial grid.
      Specified by:
      getDeltaR in interface PolarAxes
    • setDeltaR

      public void setDeltaR(double dr)
      Sets the spacing of the radial gridlines.
      Specified by:
      setDeltaR in interface PolarAxes
      Parameters:
      dr -
    • getDeltaTheta

      public double getDeltaTheta()
      Gets the spacing of the radial gridlines.
      Specified by:
      getDeltaTheta in interface PolarAxes
    • setDeltaTheta

      public void setDeltaTheta(double dtheta)
      Sets the spacing of the radial gridlines.
      Specified by:
      setDeltaTheta in interface PolarAxes
      Parameters:
      dtheta - in degree
    • setLabelFormat

      public void setLabelFormat(String formatString)
      Method setLabelFormat
      Parameters:
      formatString -
    • drawRAxis

      protected void drawRAxis(double dr, double rmax, DrawingPanel panel, Graphics g)
      Draws the spokes for the polar plot.
      Parameters:
      panel -
      g -
    • drawRings

      public double drawRings(double rmax, DrawingPanel panel, Graphics g)
      Draws the rings for the polar plot.
      Specified by:
      drawRings in interface PolarAxes
      Parameters:
      panel -
      g -
      Returns:
      double the ring separation used
    • drawSpokes

      public void drawSpokes(double rmax, DrawingPanel panel, Graphics g)
      Draws the spokes for the polar plot.
      Specified by:
      drawSpokes in interface PolarAxes
      Parameters:
      panel -
      g -