Package org.krysalis.jcharts.properties

Examples of org.krysalis.jcharts.properties.AxisProperties


//todo what about ScaleCalculator implementations?

  /*****************************************************************************************/
  private void numberOfItemsOnYAxis() throws ChartDataException
  {
    AxisProperties axisProperties = new AxisProperties();
    DataAxisProperties dataAxisProperties = (DataAxisProperties) axisProperties.getYAxisProperties();
    dataAxisProperties.setNumItems( 8 );

    super.exportImage( this.getChart( axisProperties ), "numberOfItemsOnYAxis" );
  }
View Full Code Here



  /*****************************************************************************************/
  private void gridLines() throws ChartDataException
  {
    AxisProperties axisProperties = new AxisProperties();

    ChartStroke xAxisGridLines = new ChartStroke( new BasicStroke( 1.0f ), Color.red );
    axisProperties.getXAxisProperties().setGridLineChartStroke( xAxisGridLines );
    axisProperties.getXAxisProperties().setShowGridLines( AxisTypeProperties.GRID_LINES_ONLY_WITH_LABELS );

    axisProperties.getYAxisProperties().setShowGridLines( AxisTypeProperties.GRID_LINES_NONE );


    double[][] data = {{3444d, 1506.3d, 2777d, 2550.345d, 659.667d, 950.6644d, 4500.3453d, 1200.67583d, 3000.4354d, 1268.0001d, 2444.432d, 5003d}};
    String[] xAxisLabels = {"January", "Febuary", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"};
    String[] legendLabels = {"New Bugs in Windows Per Month"};
View Full Code Here


  /*****************************************************************************************/
  private void dollarSigns() throws ChartDataException
  {
    AxisProperties axisProperties = new AxisProperties();
    DataAxisProperties dataAxisProperties = (DataAxisProperties) axisProperties.getYAxisProperties();
    dataAxisProperties.setUseDollarSigns( true );
    super.exportImage( this.getChart( axisProperties ), "dollarSigns" );
  }
View Full Code Here


  /*****************************************************************************************/
  private void commas() throws ChartDataException
  {
    AxisProperties axisProperties = new AxisProperties();
    DataAxisProperties dataAxisProperties = (DataAxisProperties) axisProperties.getYAxisProperties();
    dataAxisProperties.setUseCommas( false );
    super.exportImage( this.getChart( axisProperties ), "commas" );
  }
View Full Code Here


  /*****************************************************************************************/
  private void axisBackgroundPaint() throws ChartDataException
  {
    AxisProperties axisProperties = new AxisProperties();
    axisProperties.setBackgroundPaint( Color.yellow );
    super.exportImage( this.getChart( axisProperties ), "axisBackground" );
  }
View Full Code Here


    DataSeries dataSeries = new DataSeries( xAxisLabels, null, yAxisTitle, title );
    dataSeries.addIAxisPlotDataSet( axisChartDataSet );

    AxisChart axisChart = new AxisChart( dataSeries, new ChartProperties(), new AxisProperties(), new LegendProperties(), width, height );
    super.exportImage( axisChart, "axisTitles" );

    AxisProperties axisProperties = new AxisProperties();
    ChartFont yAxisFont = new ChartFont( new Font( "Arial Narrow", Font.BOLD, 14 ), Color.blue );
    axisProperties.getYAxisProperties().setAxisTitleChartFont( yAxisFont );

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


  /*****************************************************************************************/
  private void zeroLine() throws ChartDataException, PropertyException
  {
    AxisProperties axisProperties = new AxisProperties();

    DataAxisProperties dataAxisProperties = (DataAxisProperties) axisProperties.getYAxisProperties();
    dataAxisProperties.setUserDefinedScale( -2000, 1200 );
    dataAxisProperties.setShowZeroLine( false );
    super.exportImage( this.getChart( axisProperties ), "noZeroLine" );

    dataAxisProperties.setShowZeroLine( true );
View Full Code Here


  /*****************************************************************************************/
  private void scaleFont() throws ChartDataException
  {
    AxisProperties axisProperties = new AxisProperties();
    ChartFont xScaleChartFont = new ChartFont( new Font( "Georgia Negreta cursiva", Font.PLAIN, 13 ), Color.blue );
    axisProperties.getXAxisProperties().setScaleChartFont( xScaleChartFont );
    super.exportImage( this.getChart( axisProperties ), "scaleFont" );
  }
View Full Code Here


  /*****************************************************************************************/
  private void verticalXAxisLabels() throws ChartDataException
  {
    AxisProperties axisProperties = new AxisProperties();
    axisProperties.setXAxisLabelsAreVertical( true );
    super.exportImage( this.getChart( axisProperties ), "verticalXAxisLabels" );
  }
View Full Code Here


  /*****************************************************************************************/
  private void tickMarks() throws ChartDataException
  {
    AxisProperties axisProperties = new AxisProperties();
    axisProperties.getXAxisProperties().setShowTicks( AxisTypeProperties.TICKS_ONLY_WITH_LABELS );
    super.exportImage( this.getChart( axisProperties ), "ticksWithLabels" );


    axisProperties = new AxisProperties();
    axisProperties.getXAxisProperties().setShowTicks( AxisTypeProperties.TICKS_NONE );
    super.exportImage( this.getChart( axisProperties ), "noTicks" );


    axisProperties = new AxisProperties();
    ChartStroke xTicks = new ChartStroke( new BasicStroke( 1.0f ), Color.blue );
    axisProperties.getXAxisProperties().setTickChartStroke( xTicks );

    ChartStroke yTicks = new ChartStroke( new BasicStroke( 1.0f ), Color.green );
    axisProperties.getYAxisProperties().setTickChartStroke( yTicks );

    super.exportImage( this.getChart( axisProperties ), "tickColors" );


    axisProperties = new AxisProperties();
    ChartStroke xTickStroke = new ChartStroke( new BasicStroke( 2.0f ), Color.blue );
    axisProperties.getXAxisProperties().setTickChartStroke( xTickStroke );
    super.exportImage( this.getChart( axisProperties ), "tickStroke" );
  }
View Full Code Here

TOP

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

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.