Class CategoryStepRenderer

All Implemented Interfaces:
Serializable, Cloneable, CategoryItemRenderer, org.jfree.util.PublicCloneable

public class CategoryStepRenderer
extends AbstractCategoryItemRenderer
implements Cloneable, org.jfree.util.PublicCloneable, Serializable
A "step" renderer similar to XYStepRenderer but that can be used with the CategoryPlot class.
Author:
Brian Cole
See Also:
Serialized Form
  • Field Details

    • STAGGER_WIDTH

      public static final int STAGGER_WIDTH
      The stagger width.
      See Also:
      Constant Field Values
  • Constructor Details

    • CategoryStepRenderer

      public CategoryStepRenderer()
      Creates a new renderer (stagger defaults to false).
    • CategoryStepRenderer

      public CategoryStepRenderer​(boolean stagger)
      Creates a new renderer.
      Parameters:
      stagger - should the horizontal part of the step be staggered by series?
  • Method Details

    • getStagger

      public boolean getStagger()
      Returns the flag that controls whether the series steps are staggered.
      Returns:
      A boolean.
    • setStagger

      public void setStagger​(boolean shouldStagger)
      Sets the flag that controls whether or not the series steps are staggered.
      Parameters:
      shouldStagger - a boolean.
    • drawItem

      public void drawItem​(Graphics2D g2, CategoryItemRendererState state, Rectangle2D dataArea, CategoryPlot plot, CategoryAxis domainAxis, ValueAxis rangeAxis, CategoryDataset dataset, int row, int column)
      Draw a single data item.
      Specified by:
      drawItem in interface CategoryItemRenderer
      Parameters:
      g2 - the graphics device.
      state - the renderer state.
      dataArea - the area in which the data is drawn.
      plot - the plot.
      domainAxis - the domain axis.
      rangeAxis - the range axis.
      dataset - the dataset.
      row - the row index (zero-based).
      column - the column index (zero-based).