public static void setupLegendTitle(LegendTitle legend) { if (legend != null) { legend.setBorder(0, 0, 0, 0); legend.setItemPaint(ChartDefaults.legendTextColor); legend.setMargin(2, 2, 2, 2); } } }
public static void setupLegendTitle(LegendTitle legend) { if (legend != null) { legend.setBorder(0, 0, 0, 0); legend.setItemPaint(ChartDefaults.legendTextColor); legend.setMargin(2,2,2,2); } } }
/** * Creates a legend for the specified plot. * * @param plot The plot. * @return The legend for the plot. */ private LegendTitle createLegend(Plot plot) { LegendTitle legend = new LegendTitle(plot); legend.setMargin(new RectangleInsets(1.0, 1.0, 1.0, 1.0)); legend.setFrame(new LineBorder()); legend.setBackgroundPaint(Color.white); legend.setPosition(RectangleEdge.BOTTOM); return legend; }
LegendTitle legend = (LegendTitle) chart.getSubtitle(0); legend.setPosition(RectangleEdge.RIGHT); legend.setMargin(new RectangleInsets(UnitType.ABSOLUTE, 0, 4, 0, 4)); chart.setBorderPaint(Color.black); chart.setBorderVisible(true);
LegendTitle legend = (LegendTitle) chart.getSubtitle(0); legend.setPosition(RectangleEdge.RIGHT); legend.setMargin(new RectangleInsets(UnitType.ABSOLUTE, 0, 4, 0, 4)); chart.setBorderPaint(Color.black); chart.setBorderVisible(true);
legend.setMargin(new RectangleInsets(1.0, 1.0, 1.0, 1.0)); legend.setFrame(new LineBorder()); legend.setBackgroundPaint(Color.white);
legend.setMargin(new RectangleInsets(1.0, 1.0, 1.0, 1.0)); legend.setBackgroundPaint(Color.WHITE); legend.setPosition(RectangleEdge.BOTTOM);
legend.setItemFont(legendItemFont); int legendMargin = 10; legend.setMargin(0.0, legendMargin, legendMargin, legendMargin); legend.setBackgroundPaint(transparentColor);
legend.setItemFont(legendItemFont); int legendMargin = 10; legend.setMargin(0.0, legendMargin, legendMargin, legendMargin); legend.setBackgroundPaint(transparentColor);