Package org.krysalis.jcharts.properties

Examples of org.krysalis.jcharts.properties.BarChartProperties


   * @throws PropertyException
   * @throws ChartDataException
   *****************************************************************************************/
  public static void main( String[] args ) throws PropertyException, ChartDataException
  {
    BarChartProperties barChartProperties = new BarChartProperties();

    //BackgroundRenderer backgroundRenderer = new BackgroundRenderer( new Color( 20, 20, 20, 50 ) );
    //barChartProperties.addPreRenderEventListener( backgroundRenderer );

/*
 
View Full Code Here


    String xAxisTitle = "Months";
    String yAxisTitle = "Bugs";
    String title = "Micro$oft At Work";

    DataSeries dataSeries = new DataSeries( xAxisLabels, xAxisTitle, yAxisTitle, title );
    AxisChartDataSet axisChartDataSet = new AxisChartDataSet( data, legendLabels, paints, ChartType.BAR, new BarChartProperties() );

    dataSeries.addIAxisPlotDataSet( axisChartDataSet );

    AxisChart axisChart = new AxisChart( dataSeries, new ChartProperties(), axisProperties, new LegendProperties(), width, height );
    super.exportImage( axisChart, "horizontalPlots" );
View Full Code Here

   * @param iAxisChartDataSet
   **************************************************************************************/
  static void render( AxisChart axisChart, IAxisChartDataSet iAxisChartDataSet )
  {
    Graphics2D g2d = axisChart.getGraphics2D();
    BarChartProperties barChartProperties = (BarChartProperties) iAxisChartDataSet.getChartTypeProperties();
    float barWidth;

    //---y axis position on screen to start drawing.
    float startingX;
    float startingY;
    float width;
    float height;

    if( axisChart.getAxisProperties().isPlotHorizontal() )
    {
      barWidth = axisChart.getYAxis().getScalePixelWidth() * barChartProperties.getPercentage();
      startingX = axisChart.getXAxis().getZeroLineCoordinate();
      startingY = axisChart.getYAxis().getLastTickY() - (barWidth / 2);
      width = 0;
      height = barWidth;
      Rectangle2D.Float rectangle = new Rectangle2D.Float( startingX, startingY, width, height );

      BarChart.horizontalPlotaxisChart,
                        iAxisChartDataSet,
                        barChartProperties,
                        g2d,
                        rectangle,
                        startingX );
    }
    else
    {
      barWidth = axisChart.getXAxis().getScalePixelWidth() * barChartProperties.getPercentage();
      startingX = axisChart.getXAxis().getTickStart() - (barWidth / 2);
      startingY = axisChart.getYAxis().getZeroLineCoordinate();
      width = barWidth;
      height = 0;
      Rectangle2D.Float rectangle = new Rectangle2D.Float( startingX, startingY, width, height );
View Full Code Here

   * Separate this so can use for combo chart test
   *
   ******************************************************************************************/
  static ChartTypeProperties getChartTypeProperties( int numberOfDataSets )
  {
    BarChartProperties barChartProperties = new BarChartProperties();
    barChartProperties.setWidthPercentage( 1f );

    return barChartProperties;
  }
View Full Code Here

   * @throws PropertyException
   * @throws ChartDataException
   *****************************************************************************************/
  public static void main( String[] args ) throws PropertyException, ChartDataException
  {
    BarChartProperties barChartProperties = new BarChartProperties();

    //BackgroundRenderer backgroundRenderer = new BackgroundRenderer( new Color( 20, 20, 20, 50 ) );
    //barChartProperties.addPreRenderEventListener( backgroundRenderer );

/*
 
View Full Code Here

TOP

Related Classes of org.krysalis.jcharts.properties.BarChartProperties

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.