Example usage for org.jfree.chart.axis SymbolicAxis setLowerMargin

List of usage examples for org.jfree.chart.axis SymbolicAxis setLowerMargin

Introduction

In this page you can find the example usage for org.jfree.chart.axis SymbolicAxis setLowerMargin.

Prototype

public void setLowerMargin(double margin) 

Source Link

Document

Sets the lower margin for the axis (as a percentage of the axis range) and sends an AxisChangeEvent to all registered listeners.

Usage

From source file:de.berlios.statcvs.xml.report.ActivityProgressionChart.java

private JFreeChart createContourPlot() {
    Grouper grouper = settings.getGrouper(new ModuleGrouper(settings.getModules(content)));

    ContourDataset data = createDataset(grouper);
    if (data == null) {
        return null;
    }// w  ww . ja  v  a  2  s.  c o  m

    ValueAxis xAxis = new DateAxis(I18n.tr("Date"));

    SymbolicAxis yAxis = new SymbolicAxis(grouper.getName(), (String[]) groupNames.toArray(new String[0]));
    yAxis.setInverted(true);
    yAxis.setLowerMargin(0.0);
    yAxis.setUpperMargin(0.0);

    ColorBar zAxis = new ColorBar(I18n.tr("Commit Activity (%)"));
    zAxis.getAxis();

    ContourPlot plot = new ContourPlot(data, xAxis, yAxis, zAxis);
    //plot.setRenderAsPoints(true);
    // don't use plot units for ratios when x axis is date
    plot.setDataAreaRatio(0.0);
    plot.setColorBarLocation(RectangleEdge.BOTTOM);

    return new JFreeChart(settings.getProjectName(), null, plot, false);
}