Examples of JRDesignScatterPlot


Examples of net.sf.jasperreports.charts.design.JRDesignScatterPlot

        dataset = new JRDesignPieDataset(dataset);
        plot = new JRDesignPie3DPlot(plot, this);
        break;
      case CHART_TYPE_SCATTER:
        dataset = new JRDesignXyDataset(dataset);
        plot = new JRDesignScatterPlot(plot, this);
        break;
      case CHART_TYPE_STACKEDBAR:
        dataset = new JRDesignCategoryDataset(dataset);
        plot = new JRDesignBarPlot(plot, this);
        break;
View Full Code Here

Examples of net.sf.jasperreports.charts.design.JRDesignScatterPlot

  private static final String ATTRIBUTE_isShowShapes = "isShowShapes";
  private static final String ATTRIBUTE_isShowLines = "isShowLines";
 
  public Object createObject( Attributes attrs ){
    JRChart chart = (JRChart)digester.peek();
    JRDesignScatterPlot plot = (JRDesignScatterPlot)chart.getPlot();
   
    String isShowShapes = attrs.getValue( ATTRIBUTE_isShowShapes );
    if( isShowShapes != null && isShowShapes.length() > 0 ){
      plot.setShowShapes(Boolean.valueOf(isShowShapes) );
    }
   
    String isShowLines = attrs.getValue( ATTRIBUTE_isShowLines );
    if( isShowLines != null && isShowLines.length() > 0 ){
      plot.setShowLines(Boolean.valueOf(isShowLines) );
    }
   
    return plot;
  }
View Full Code Here

Examples of net.sf.jasperreports.charts.design.JRDesignScatterPlot

    return yAxisFormat;
  }
 
  public void transform(DynamicJasperDesign design, JRChartPlot plot, String name) {
    super.transform(design, plot, name);
    JRDesignScatterPlot scatterPlot = (JRDesignScatterPlot) plot;
   
    StringExpression xAxisLabelExp = getXAxisFormat().getLabelExpression();
    if (xAxisLabelExp != null) {
      JRDesignExpression exp = ExpressionUtils.createAndRegisterExpression(design, "xAxisLabel_" + name, xAxisLabelExp);
      scatterPlot.setXAxisLabelExpression(exp);
    }
    if (xAxisFormat.getTickLabelMask() != null)
      scatterPlot.setXAxisTickLabelMask(xAxisFormat.getTickLabelMask())
    if (xAxisFormat.getLabelColor() != null)
      scatterPlot.setXAxisLabelColor(xAxisFormat.getLabelColor());
    if (xAxisFormat.getLabelFont() != null)
      scatterPlot.setXAxisLabelFont(xAxisFormat.getLabelFont().transform());
    if (xAxisFormat.getLineColor() != null)
      scatterPlot.setXAxisLineColor(xAxisFormat.getLineColor());   
    if (xAxisFormat.getTickLabelColor() != null)
      scatterPlot.setXAxisTickLabelColor(xAxisFormat.getTickLabelColor());
    if (xAxisFormat.getTickLabelFont() != null)
      scatterPlot.setXAxisTickLabelFont(xAxisFormat.getTickLabelFont().transform());
    CustomExpression xAxisRangeMinValueExp = getXAxisFormat().getRangeMinValueExpression();
    if (xAxisRangeMinValueExp != null) {
      JRDesignExpression exp = ExpressionUtils.createAndRegisterExpression(design, "xAxisRangeMinValue_" + name, xAxisRangeMinValueExp);
      scatterPlot.setDomainAxisMinValueExpression(exp);
    }
    CustomExpression xAxisRangeMaxValueExp = getXAxisFormat().getRangeMaxValueExpression();
    if (xAxisRangeMaxValueExp != null) {
      JRDesignExpression exp = ExpressionUtils.createAndRegisterExpression(design, "xAxisRangeMaxValue_" + name, xAxisRangeMaxValueExp);
      scatterPlot.setDomainAxisMaxValueExpression(exp);
    }
   
    StringExpression yAxisLabelExp = getYAxisFormat().getLabelExpression();
    if (yAxisLabelExp != null) {
      JRDesignExpression exp = ExpressionUtils.createAndRegisterExpression(design, "yAxisLabel_" + name, yAxisLabelExp);
      scatterPlot.setYAxisLabelExpression(exp);
    }
    if (yAxisFormat.getTickLabelMask() != null)
      scatterPlot.setYAxisTickLabelMask(yAxisFormat.getTickLabelMask())
    if (yAxisFormat.getLabelColor() != null)
      scatterPlot.setYAxisLabelColor(yAxisFormat.getLabelColor());
    if (yAxisFormat.getLabelFont() != null)
      scatterPlot.setYAxisLabelFont(yAxisFormat.getLabelFont().transform());
    if (yAxisFormat.getLineColor() != null)
      scatterPlot.setYAxisLineColor(yAxisFormat.getLineColor());   
    if (yAxisFormat.getTickLabelColor() != null)
      scatterPlot.setYAxisTickLabelColor(yAxisFormat.getTickLabelColor());
    if (yAxisFormat.getTickLabelFont() != null)
      scatterPlot.setYAxisTickLabelFont(yAxisFormat.getTickLabelFont().transform());
    CustomExpression yAxisRangeMinValueExp = getYAxisFormat().getRangeMinValueExpression();
    if (yAxisRangeMinValueExp != null) {
      JRDesignExpression exp = ExpressionUtils.createAndRegisterExpression(design, "yAxisRangeMinValue_" + name, yAxisRangeMinValueExp);
      scatterPlot.setRangeAxisMinValueExpression(exp);
    }
    CustomExpression yAxisRangeMaxValueExp = getYAxisFormat().getRangeMaxValueExpression();
    if (yAxisRangeMaxValueExp != null) {
      JRDesignExpression exp = ExpressionUtils.createAndRegisterExpression(design, "yAxisRangeMaxValue_" + name, yAxisRangeMaxValueExp);
      scatterPlot.setRangeAxisMaxValueExpression(exp);
    }
   
    if (showShapes != null)
      scatterPlot.setShowShapes(showShapes);
    if (showLines != null)
      scatterPlot.setShowLines(showLines);
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.