Example usage for org.jfree.chart ChartPanel setAlignmentY

List of usage examples for org.jfree.chart ChartPanel setAlignmentY

Introduction

In this page you can find the example usage for org.jfree.chart ChartPanel setAlignmentY.

Prototype

@BeanProperty(description = "The preferred vertical alignment of the component.")
public void setAlignmentY(float alignmentY) 

Source Link

Document

Sets the vertical alignment.

Usage

From source file:com.devoteam.srit.xmlloader.core.report.derived.DerivedCounter.java

public ChartPanel getChartPanel() {
    ChartPanel chartPanel = new ChartPanel(null);
    chartPanel.setLayout(new javax.swing.BoxLayout(chartPanel, javax.swing.BoxLayout.Y_AXIS));
    chartPanel.setAlignmentX(java.awt.Component.LEFT_ALIGNMENT);
    chartPanel.setAlignmentY(java.awt.Component.TOP_ALIGNMENT);

    if (timeChart == null) {
        timeChart = getTimeChart();//  w  w w . j a  va 2s .c o  m
    }
    chartPanel.add(new ChartPanel(timeChart));

    if (this instanceof StatValue) {
        if (histogramChart == null) {
            histogramChart = getHistogramChart();
        }
        chartPanel.add(new ChartPanel(histogramChart));
    }

    return chartPanel;
}