Java Code Examples for org.jfree.util.UnitType#RELATIVE
The following examples show how to use
org.jfree.util.UnitType#RELATIVE .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: ThermometerPlot.java From openstock with GNU General Public License v3.0 | 6 votes |
/** * Creates a new thermometer plot, using default attributes where necessary. * * @param dataset the data set. */ public ThermometerPlot(ValueDataset dataset) { super(); this.padding = new RectangleInsets(UnitType.RELATIVE, 0.05, 0.05, 0.05, 0.05); this.dataset = dataset; if (dataset != null) { dataset.addChangeListener(this); } NumberAxis axis = new NumberAxis(null); axis.setStandardTickUnits(NumberAxis.createIntegerTickUnits()); axis.setAxisLineVisible(false); axis.setPlot(this); axis.addChangeListener(this); this.rangeAxis = axis; setAxisRange(); }
Example 2
Source File: ThermometerPlot.java From buffer_bci with GNU General Public License v3.0 | 6 votes |
/** * Creates a new thermometer plot, using default attributes where necessary. * * @param dataset the data set. */ public ThermometerPlot(ValueDataset dataset) { super(); this.padding = new RectangleInsets(UnitType.RELATIVE, 0.05, 0.05, 0.05, 0.05); this.dataset = dataset; if (dataset != null) { dataset.addChangeListener(this); } NumberAxis axis = new NumberAxis(null); axis.setStandardTickUnits(NumberAxis.createIntegerTickUnits()); axis.setAxisLineVisible(false); axis.setPlot(this); axis.addChangeListener(this); this.rangeAxis = axis; setAxisRange(); }
Example 3
Source File: ThermometerPlot.java From SIMVA-SoS with Apache License 2.0 | 6 votes |
/** * Creates a new thermometer plot, using default attributes where necessary. * * @param dataset the data set. */ public ThermometerPlot(ValueDataset dataset) { super(); this.padding = new RectangleInsets(UnitType.RELATIVE, 0.05, 0.05, 0.05, 0.05); this.dataset = dataset; if (dataset != null) { dataset.addChangeListener(this); } NumberAxis axis = new NumberAxis(null); axis.setStandardTickUnits(NumberAxis.createIntegerTickUnits()); axis.setAxisLineVisible(false); axis.setPlot(this); axis.addChangeListener(this); this.rangeAxis = axis; setAxisRange(); }
Example 4
Source File: BlockBorderTest.java From ECG-Viewer with GNU General Public License v2.0 | 6 votes |
/** * Confirm that the equals() method can distinguish all the required fields. */ @Test public void testEquals() { BlockBorder b1 = new BlockBorder(new RectangleInsets(1.0, 2.0, 3.0, 4.0), Color.red); BlockBorder b2 = new BlockBorder(new RectangleInsets(1.0, 2.0, 3.0, 4.0), Color.red); assertTrue(b1.equals(b2)); assertTrue(b2.equals(b2)); // insets b1 = new BlockBorder(new RectangleInsets(UnitType.RELATIVE, 1.0, 2.0, 3.0, 4.0), Color.red); assertFalse(b1.equals(b2)); b2 = new BlockBorder(new RectangleInsets(UnitType.RELATIVE, 1.0, 2.0, 3.0, 4.0), Color.red); assertTrue(b1.equals(b2)); // paint b1 = new BlockBorder(new RectangleInsets(1.0, 2.0, 3.0, 4.0), Color.blue); assertFalse(b1.equals(b2)); b2 = new BlockBorder(new RectangleInsets(1.0, 2.0, 3.0, 4.0), Color.blue); assertTrue(b1.equals(b2)); }
Example 5
Source File: BlockBorderTest.java From buffer_bci with GNU General Public License v3.0 | 6 votes |
/** * Confirm that the equals() method can distinguish all the required fields. */ @Test public void testEquals() { BlockBorder b1 = new BlockBorder(new RectangleInsets(1.0, 2.0, 3.0, 4.0), Color.red); BlockBorder b2 = new BlockBorder(new RectangleInsets(1.0, 2.0, 3.0, 4.0), Color.red); assertTrue(b1.equals(b2)); assertTrue(b2.equals(b2)); // insets b1 = new BlockBorder(new RectangleInsets(UnitType.RELATIVE, 1.0, 2.0, 3.0, 4.0), Color.red); assertFalse(b1.equals(b2)); b2 = new BlockBorder(new RectangleInsets(UnitType.RELATIVE, 1.0, 2.0, 3.0, 4.0), Color.red); assertTrue(b1.equals(b2)); // paint b1 = new BlockBorder(new RectangleInsets(1.0, 2.0, 3.0, 4.0), Color.blue); assertFalse(b1.equals(b2)); b2 = new BlockBorder(new RectangleInsets(1.0, 2.0, 3.0, 4.0), Color.blue); assertTrue(b1.equals(b2)); }
Example 6
Source File: ThermometerPlot.java From opensim-gui with Apache License 2.0 | 6 votes |
/** * Creates a new thermometer plot, using default attributes where necessary. * * @param dataset the data set. */ public ThermometerPlot(ValueDataset dataset) { super(); this.padding = new RectangleInsets(UnitType.RELATIVE, 0.05, 0.05, 0.05, 0.05); this.dataset = dataset; if (dataset != null) { dataset.addChangeListener(this); } NumberAxis axis = new NumberAxis(null); axis.setStandardTickUnits(NumberAxis.createIntegerTickUnits()); axis.setAxisLineVisible(false); setRangeAxis(axis); setAxisRange(); }
Example 7
Source File: ThermometerPlot.java From ccu-historian with GNU General Public License v3.0 | 6 votes |
/** * Creates a new thermometer plot, using default attributes where necessary. * * @param dataset the data set. */ public ThermometerPlot(ValueDataset dataset) { super(); this.padding = new RectangleInsets(UnitType.RELATIVE, 0.05, 0.05, 0.05, 0.05); this.dataset = dataset; if (dataset != null) { dataset.addChangeListener(this); } NumberAxis axis = new NumberAxis(null); axis.setStandardTickUnits(NumberAxis.createIntegerTickUnits()); axis.setAxisLineVisible(false); axis.setPlot(this); axis.addChangeListener(this); this.rangeAxis = axis; setAxisRange(); }
Example 8
Source File: ThermometerPlot.java From buffer_bci with GNU General Public License v3.0 | 6 votes |
/** * Creates a new thermometer plot, using default attributes where necessary. * * @param dataset the data set. */ public ThermometerPlot(ValueDataset dataset) { super(); this.padding = new RectangleInsets(UnitType.RELATIVE, 0.05, 0.05, 0.05, 0.05); this.dataset = dataset; if (dataset != null) { dataset.addChangeListener(this); } NumberAxis axis = new NumberAxis(null); axis.setStandardTickUnits(NumberAxis.createIntegerTickUnits()); axis.setAxisLineVisible(false); axis.setPlot(this); axis.addChangeListener(this); this.rangeAxis = axis; setAxisRange(); }
Example 9
Source File: BlockBorderTest.java From openstock with GNU General Public License v3.0 | 6 votes |
/** * Confirm that the equals() method can distinguish all the required fields. */ @Test public void testEquals() { BlockBorder b1 = new BlockBorder(new RectangleInsets(1.0, 2.0, 3.0, 4.0), Color.red); BlockBorder b2 = new BlockBorder(new RectangleInsets(1.0, 2.0, 3.0, 4.0), Color.red); assertTrue(b1.equals(b2)); assertTrue(b2.equals(b2)); // insets b1 = new BlockBorder(new RectangleInsets(UnitType.RELATIVE, 1.0, 2.0, 3.0, 4.0), Color.red); assertFalse(b1.equals(b2)); b2 = new BlockBorder(new RectangleInsets(UnitType.RELATIVE, 1.0, 2.0, 3.0, 4.0), Color.red); assertTrue(b1.equals(b2)); // paint b1 = new BlockBorder(new RectangleInsets(1.0, 2.0, 3.0, 4.0), Color.blue); assertFalse(b1.equals(b2)); b2 = new BlockBorder(new RectangleInsets(1.0, 2.0, 3.0, 4.0), Color.blue); assertTrue(b1.equals(b2)); }
Example 10
Source File: RectangleInsets.java From ccu-historian with GNU General Public License v3.0 | 5 votes |
/** * Returns the top margin. * * @param height the height of the base rectangle. * * @return The top margin (in Java2D units). */ public double calculateTopOutset(final double height) { double result = this.top; if (this.unitType == UnitType.RELATIVE) { result = (height / (1 - this.top - this.bottom)) * this.top; } return result; }
Example 11
Source File: RectangleInsets.java From ccu-historian with GNU General Public License v3.0 | 5 votes |
/** * Returns the bottom margin. * * @param height the height of the base rectangle. * * @return The bottom margin (in Java2D units). */ public double calculateBottomInset(final double height) { double result = this.bottom; if (this.unitType == UnitType.RELATIVE) { result = (this.bottom * height); } return result; }
Example 12
Source File: RectangleInsets.java From ccu-historian with GNU General Public License v3.0 | 5 votes |
/** * Returns the bottom margin. * * @param height the height of the base rectangle. * * @return The bottom margin (in Java2D units). */ public double calculateBottomOutset(final double height) { double result = this.bottom; if (this.unitType == UnitType.RELATIVE) { result = (height / (1 - this.top - this.bottom)) * this.bottom; } return result; }
Example 13
Source File: RectangleInsets.java From ccu-historian with GNU General Public License v3.0 | 5 votes |
/** * Returns the left margin. * * @param width the width of the base rectangle. * * @return The left margin (in Java2D units). */ public double calculateLeftOutset(final double width) { double result = this.left; if (this.unitType == UnitType.RELATIVE) { result = (width / (1 - this.left - this.right)) * this.left; } return result; }
Example 14
Source File: UnitTypeFieldHandler.java From jasperreports with GNU Lesser General Public License v3.0 | 5 votes |
@Override public Object convertUponSet(Object value) { if (value == null) { return null; } return UnitType.RELATIVE.toString().equals(value) ? UnitType.RELATIVE : UnitType.ABSOLUTE.toString().equals(value) ? UnitType.ABSOLUTE : null; }
Example 15
Source File: PiePlot.java From ccu-historian with GNU General Public License v3.0 | 4 votes |
/** * Creates a plot that will draw a pie chart for the specified dataset. * * @param dataset the dataset (<code>null</code> permitted). */ public PiePlot(PieDataset dataset) { super(); this.dataset = dataset; if (dataset != null) { dataset.addChangeListener(this); } this.pieIndex = 0; this.interiorGap = DEFAULT_INTERIOR_GAP; this.circular = true; this.startAngle = DEFAULT_START_ANGLE; this.direction = Rotation.CLOCKWISE; this.minimumArcAngleToDraw = DEFAULT_MINIMUM_ARC_ANGLE_TO_DRAW; this.sectionPaint = null; this.sectionPaintMap = new PaintMap(); this.baseSectionPaint = Color.gray; this.autoPopulateSectionPaint = true; this.sectionOutlinesVisible = true; this.sectionOutlinePaint = null; this.sectionOutlinePaintMap = new PaintMap(); this.baseSectionOutlinePaint = DEFAULT_OUTLINE_PAINT; this.autoPopulateSectionOutlinePaint = false; this.sectionOutlineStroke = null; this.sectionOutlineStrokeMap = new StrokeMap(); this.baseSectionOutlineStroke = DEFAULT_OUTLINE_STROKE; this.autoPopulateSectionOutlineStroke = false; this.explodePercentages = new TreeMap(); this.labelGenerator = new StandardPieSectionLabelGenerator(); this.labelFont = DEFAULT_LABEL_FONT; this.labelPaint = DEFAULT_LABEL_PAINT; this.labelBackgroundPaint = DEFAULT_LABEL_BACKGROUND_PAINT; this.labelOutlinePaint = DEFAULT_LABEL_OUTLINE_PAINT; this.labelOutlineStroke = DEFAULT_LABEL_OUTLINE_STROKE; this.labelShadowPaint = DEFAULT_LABEL_SHADOW_PAINT; this.labelLinksVisible = true; this.labelDistributor = new PieLabelDistributor(0); this.simpleLabels = false; this.simpleLabelOffset = new RectangleInsets(UnitType.RELATIVE, 0.18, 0.18, 0.18, 0.18); this.labelPadding = new RectangleInsets(2, 2, 2, 2); this.toolTipGenerator = null; this.urlGenerator = null; this.legendLabelGenerator = new StandardPieSectionLabelGenerator(); this.legendLabelToolTipGenerator = null; this.legendLabelURLGenerator = null; this.legendItemShape = Plot.DEFAULT_LEGEND_ITEM_CIRCLE; this.ignoreNullValues = false; this.ignoreZeroValues = false; this.shadowGenerator = null; }
Example 16
Source File: PiePlot.java From ECG-Viewer with GNU General Public License v2.0 | 4 votes |
/** * Creates a plot that will draw a pie chart for the specified dataset. * * @param dataset the dataset (<code>null</code> permitted). */ public PiePlot(PieDataset dataset) { super(); this.dataset = dataset; if (dataset != null) { dataset.addChangeListener(this); } this.pieIndex = 0; this.interiorGap = DEFAULT_INTERIOR_GAP; this.circular = true; this.startAngle = DEFAULT_START_ANGLE; this.direction = Rotation.CLOCKWISE; this.minimumArcAngleToDraw = DEFAULT_MINIMUM_ARC_ANGLE_TO_DRAW; this.sectionPaint = null; this.sectionPaintMap = new PaintMap(); this.baseSectionPaint = Color.gray; this.autoPopulateSectionPaint = true; this.sectionOutlinesVisible = true; this.sectionOutlinePaint = null; this.sectionOutlinePaintMap = new PaintMap(); this.baseSectionOutlinePaint = DEFAULT_OUTLINE_PAINT; this.autoPopulateSectionOutlinePaint = false; this.sectionOutlineStroke = null; this.sectionOutlineStrokeMap = new StrokeMap(); this.baseSectionOutlineStroke = DEFAULT_OUTLINE_STROKE; this.autoPopulateSectionOutlineStroke = false; this.explodePercentages = new TreeMap(); this.labelGenerator = new StandardPieSectionLabelGenerator(); this.labelFont = DEFAULT_LABEL_FONT; this.labelPaint = DEFAULT_LABEL_PAINT; this.labelBackgroundPaint = DEFAULT_LABEL_BACKGROUND_PAINT; this.labelOutlinePaint = DEFAULT_LABEL_OUTLINE_PAINT; this.labelOutlineStroke = DEFAULT_LABEL_OUTLINE_STROKE; this.labelShadowPaint = DEFAULT_LABEL_SHADOW_PAINT; this.labelLinksVisible = true; this.labelDistributor = new PieLabelDistributor(0); this.simpleLabels = false; this.simpleLabelOffset = new RectangleInsets(UnitType.RELATIVE, 0.18, 0.18, 0.18, 0.18); this.labelPadding = new RectangleInsets(2, 2, 2, 2); this.toolTipGenerator = null; this.urlGenerator = null; this.legendLabelGenerator = new StandardPieSectionLabelGenerator(); this.legendLabelToolTipGenerator = null; this.legendLabelURLGenerator = null; this.legendItemShape = Plot.DEFAULT_LEGEND_ITEM_CIRCLE; this.ignoreNullValues = false; this.ignoreZeroValues = false; this.shadowGenerator = null; }
Example 17
Source File: PiePlot.java From buffer_bci with GNU General Public License v3.0 | 4 votes |
/** * Creates a plot that will draw a pie chart for the specified dataset. * * @param dataset the dataset (<code>null</code> permitted). */ public PiePlot(PieDataset dataset) { super(); this.dataset = dataset; if (dataset != null) { dataset.addChangeListener(this); } this.pieIndex = 0; this.interiorGap = DEFAULT_INTERIOR_GAP; this.circular = true; this.startAngle = DEFAULT_START_ANGLE; this.direction = Rotation.CLOCKWISE; this.minimumArcAngleToDraw = DEFAULT_MINIMUM_ARC_ANGLE_TO_DRAW; this.sectionPaint = null; this.sectionPaintMap = new PaintMap(); this.baseSectionPaint = Color.gray; this.autoPopulateSectionPaint = true; this.sectionOutlinesVisible = true; this.sectionOutlinePaint = null; this.sectionOutlinePaintMap = new PaintMap(); this.baseSectionOutlinePaint = DEFAULT_OUTLINE_PAINT; this.autoPopulateSectionOutlinePaint = false; this.sectionOutlineStroke = null; this.sectionOutlineStrokeMap = new StrokeMap(); this.baseSectionOutlineStroke = DEFAULT_OUTLINE_STROKE; this.autoPopulateSectionOutlineStroke = false; this.explodePercentages = new TreeMap(); this.labelGenerator = new StandardPieSectionLabelGenerator(); this.labelFont = DEFAULT_LABEL_FONT; this.labelPaint = DEFAULT_LABEL_PAINT; this.labelBackgroundPaint = DEFAULT_LABEL_BACKGROUND_PAINT; this.labelOutlinePaint = DEFAULT_LABEL_OUTLINE_PAINT; this.labelOutlineStroke = DEFAULT_LABEL_OUTLINE_STROKE; this.labelShadowPaint = DEFAULT_LABEL_SHADOW_PAINT; this.labelLinksVisible = true; this.labelDistributor = new PieLabelDistributor(0); this.simpleLabels = false; this.simpleLabelOffset = new RectangleInsets(UnitType.RELATIVE, 0.18, 0.18, 0.18, 0.18); this.labelPadding = new RectangleInsets(2, 2, 2, 2); this.toolTipGenerator = null; this.urlGenerator = null; this.legendLabelGenerator = new StandardPieSectionLabelGenerator(); this.legendLabelToolTipGenerator = null; this.legendLabelURLGenerator = null; this.legendItemShape = Plot.DEFAULT_LEGEND_ITEM_CIRCLE; this.ignoreNullValues = false; this.ignoreZeroValues = false; this.shadowGenerator = null; }
Example 18
Source File: RectangleInsetsTest.java From ccu-historian with GNU General Public License v3.0 | 4 votes |
/** * Some checks for the createAdjustedRectangle() method. */ public void testCreateAdjustedRectangleRelative() { RectangleInsets i1 = new RectangleInsets( UnitType.RELATIVE, 0.04, 0.03, 0.02, 0.01 ); Rectangle2D base = new Rectangle2D.Double(10.0, 20.0, 30.0, 40.0); // no adjustment Rectangle2D adjusted = i1.createAdjustedRectangle( base, LengthAdjustmentType.NO_CHANGE, LengthAdjustmentType.NO_CHANGE ); assertEquals(new Rectangle2D.Double(10.0, 20.0, 30.0, 40.0), adjusted); // expand height adjusted = i1.createAdjustedRectangle( base, LengthAdjustmentType.NO_CHANGE, LengthAdjustmentType.EXPAND ); assertEquals(10.0, adjusted.getX(), EPSILON); assertEquals(18.2978723404, adjusted.getY(), EPSILON); assertEquals(30.0, adjusted.getWidth(), EPSILON); assertEquals(42.553191489, adjusted.getHeight(), EPSILON); // contract height adjusted = i1.createAdjustedRectangle( base, LengthAdjustmentType.NO_CHANGE, LengthAdjustmentType.CONTRACT ); assertEquals(10.0, adjusted.getX(), EPSILON); assertEquals(21.6, adjusted.getY(), EPSILON); assertEquals(30.0, adjusted.getWidth(), EPSILON); assertEquals(37.6, adjusted.getHeight(), EPSILON); // expand width adjusted = i1.createAdjustedRectangle( base, LengthAdjustmentType.EXPAND, LengthAdjustmentType.NO_CHANGE ); assertEquals(9.0625, adjusted.getX(), EPSILON); assertEquals(20.0, adjusted.getY(), EPSILON); assertEquals(31.25, adjusted.getWidth(), EPSILON); assertEquals(40.0, adjusted.getHeight(), EPSILON); // contract width adjusted = i1.createAdjustedRectangle( base, LengthAdjustmentType.CONTRACT, LengthAdjustmentType.NO_CHANGE ); assertEquals(10.9, adjusted.getX(), EPSILON); assertEquals(20.0, adjusted.getY(), EPSILON); assertEquals(28.8, adjusted.getWidth(), EPSILON); assertEquals(40.0, adjusted.getHeight(), EPSILON); // expand both adjusted = i1.createAdjustedRectangle( base, LengthAdjustmentType.EXPAND, LengthAdjustmentType.EXPAND ); assertEquals(9.0625, adjusted.getX(), EPSILON); assertEquals(18.2978723404, adjusted.getY(), EPSILON); assertEquals(31.25, adjusted.getWidth(), EPSILON); assertEquals(42.553191489, adjusted.getHeight(), EPSILON); // expand width contract height adjusted = i1.createAdjustedRectangle( base, LengthAdjustmentType.EXPAND, LengthAdjustmentType.CONTRACT ); assertEquals(9.0625, adjusted.getX(), EPSILON); assertEquals(21.6, adjusted.getY(), EPSILON); assertEquals(31.25, adjusted.getWidth(), EPSILON); assertEquals(37.6, adjusted.getHeight(), EPSILON); // contract both adjusted = i1.createAdjustedRectangle( base, LengthAdjustmentType.CONTRACT, LengthAdjustmentType.CONTRACT ); assertEquals(10.9, adjusted.getX(), EPSILON); assertEquals(21.6, adjusted.getY(), EPSILON); assertEquals(28.8, adjusted.getWidth(), EPSILON); assertEquals(37.6, adjusted.getHeight(), EPSILON); // contract width expand height adjusted = i1.createAdjustedRectangle( base, LengthAdjustmentType.CONTRACT, LengthAdjustmentType.EXPAND ); assertEquals(10.9, adjusted.getX(), EPSILON); assertEquals(18.2978723404, adjusted.getY(), EPSILON); assertEquals(28.8, adjusted.getWidth(), EPSILON); assertEquals(42.553191489, adjusted.getHeight(), EPSILON); }
Example 19
Source File: PiePlot.java From buffer_bci with GNU General Public License v3.0 | 4 votes |
/** * Creates a plot that will draw a pie chart for the specified dataset. * * @param dataset the dataset (<code>null</code> permitted). */ public PiePlot(PieDataset dataset) { super(); this.dataset = dataset; if (dataset != null) { dataset.addChangeListener(this); } this.pieIndex = 0; this.interiorGap = DEFAULT_INTERIOR_GAP; this.circular = true; this.startAngle = DEFAULT_START_ANGLE; this.direction = Rotation.CLOCKWISE; this.minimumArcAngleToDraw = DEFAULT_MINIMUM_ARC_ANGLE_TO_DRAW; this.sectionPaint = null; this.sectionPaintMap = new PaintMap(); this.baseSectionPaint = Color.gray; this.autoPopulateSectionPaint = true; this.sectionOutlinesVisible = true; this.sectionOutlinePaint = null; this.sectionOutlinePaintMap = new PaintMap(); this.baseSectionOutlinePaint = DEFAULT_OUTLINE_PAINT; this.autoPopulateSectionOutlinePaint = false; this.sectionOutlineStroke = null; this.sectionOutlineStrokeMap = new StrokeMap(); this.baseSectionOutlineStroke = DEFAULT_OUTLINE_STROKE; this.autoPopulateSectionOutlineStroke = false; this.explodePercentages = new TreeMap(); this.labelGenerator = new StandardPieSectionLabelGenerator(); this.labelFont = DEFAULT_LABEL_FONT; this.labelPaint = DEFAULT_LABEL_PAINT; this.labelBackgroundPaint = DEFAULT_LABEL_BACKGROUND_PAINT; this.labelOutlinePaint = DEFAULT_LABEL_OUTLINE_PAINT; this.labelOutlineStroke = DEFAULT_LABEL_OUTLINE_STROKE; this.labelShadowPaint = DEFAULT_LABEL_SHADOW_PAINT; this.labelLinksVisible = true; this.labelDistributor = new PieLabelDistributor(0); this.simpleLabels = false; this.simpleLabelOffset = new RectangleInsets(UnitType.RELATIVE, 0.18, 0.18, 0.18, 0.18); this.labelPadding = new RectangleInsets(2, 2, 2, 2); this.toolTipGenerator = null; this.urlGenerator = null; this.legendLabelGenerator = new StandardPieSectionLabelGenerator(); this.legendLabelToolTipGenerator = null; this.legendLabelURLGenerator = null; this.legendItemShape = Plot.DEFAULT_LEGEND_ITEM_CIRCLE; this.ignoreNullValues = false; this.ignoreZeroValues = false; this.shadowGenerator = null; }
Example 20
Source File: PiePlot.java From openstock with GNU General Public License v3.0 | 4 votes |
/** * Creates a plot that will draw a pie chart for the specified dataset. * * @param dataset the dataset (<code>null</code> permitted). */ public PiePlot(PieDataset dataset) { super(); this.dataset = dataset; if (dataset != null) { dataset.addChangeListener(this); } this.pieIndex = 0; this.interiorGap = DEFAULT_INTERIOR_GAP; this.circular = true; this.startAngle = DEFAULT_START_ANGLE; this.direction = Rotation.CLOCKWISE; this.minimumArcAngleToDraw = DEFAULT_MINIMUM_ARC_ANGLE_TO_DRAW; this.sectionPaint = null; this.sectionPaintMap = new PaintMap(); this.baseSectionPaint = Color.gray; this.autoPopulateSectionPaint = true; this.sectionOutlinesVisible = true; this.sectionOutlinePaint = null; this.sectionOutlinePaintMap = new PaintMap(); this.baseSectionOutlinePaint = DEFAULT_OUTLINE_PAINT; this.autoPopulateSectionOutlinePaint = false; this.sectionOutlineStroke = null; this.sectionOutlineStrokeMap = new StrokeMap(); this.baseSectionOutlineStroke = DEFAULT_OUTLINE_STROKE; this.autoPopulateSectionOutlineStroke = false; this.explodePercentages = new TreeMap(); this.labelGenerator = new StandardPieSectionLabelGenerator(); this.labelFont = DEFAULT_LABEL_FONT; this.labelPaint = DEFAULT_LABEL_PAINT; this.labelBackgroundPaint = DEFAULT_LABEL_BACKGROUND_PAINT; this.labelOutlinePaint = DEFAULT_LABEL_OUTLINE_PAINT; this.labelOutlineStroke = DEFAULT_LABEL_OUTLINE_STROKE; this.labelShadowPaint = DEFAULT_LABEL_SHADOW_PAINT; this.labelLinksVisible = true; this.labelDistributor = new PieLabelDistributor(0); this.simpleLabels = false; this.simpleLabelOffset = new RectangleInsets(UnitType.RELATIVE, 0.18, 0.18, 0.18, 0.18); this.labelPadding = new RectangleInsets(2, 2, 2, 2); this.toolTipGenerator = null; this.urlGenerator = null; this.legendLabelGenerator = new StandardPieSectionLabelGenerator(); this.legendLabelToolTipGenerator = null; this.legendLabelURLGenerator = null; this.legendItemShape = Plot.DEFAULT_LEGEND_ITEM_CIRCLE; this.ignoreNullValues = false; this.ignoreZeroValues = false; this.shadowGenerator = null; }