Examples of CTPlotArea


Examples of org.openxmlformats.schemas.drawingml.x2006.chart.CTPlotArea

        POIXMLDocumentPart xlsPart = chart.getRelations().get(0);
        XSSFWorkbook wb = new XSSFWorkbook();
        XSSFSheet sheet = wb.createSheet();

        CTChart ctChart = chart.getCTChart();
        CTPlotArea plotArea = ctChart.getPlotArea();

        CTPieChart pieChart = plotArea.getPieChartArray(0);
        //Pie Chart Series
        CTPieSer ser = pieChart.getSerArray(0);

        // Series Text
        CTSerTx tx = ser.getTx();
View Full Code Here

Examples of org.openxmlformats.schemas.drawingml.x2006.chart.CTPlotArea

   * @return a new CTChartSpace bean
   */
  private void createChart() {
    chartSpace = CTChartSpace.Factory.newInstance();
    chart = chartSpace.addNewChart();
    CTPlotArea plotArea = chart.addNewPlotArea();

    plotArea.addNewLayout();
    chart.addNewPlotVisOnly().setVal(true);

    CTPrintSettings printSettings = chartSpace.addNewPrintSettings();
    printSettings.addNewHeaderFooter();

View Full Code Here

Examples of org.openxmlformats.schemas.drawingml.x2006.chart.CTPlotArea

      chart.unsetLegend();
    }
  }

  private boolean hasAxis() {
    CTPlotArea ctPlotArea = chart.getPlotArea();
    int totalAxisCount =
      ctPlotArea.sizeOfValAxArray()  +
      ctPlotArea.sizeOfCatAxArray()  +
      ctPlotArea.sizeOfDateAxArray() +
      ctPlotArea.sizeOfSerAxArray();
    return totalAxisCount > 0;
  }
View Full Code Here

Examples of org.openxmlformats.schemas.drawingml.x2006.chart.CTPlotArea

        if (!(chart instanceof XSSFChart)) {
            throw new IllegalArgumentException("Chart must be instance of XSSFChart");
        }

        XSSFChart xssfChart = (XSSFChart) chart;
        CTPlotArea plotArea = xssfChart.getCTChart().getPlotArea();
        CTLineChart lineChart = plotArea.addNewLineChart();
        lineChart.addNewVaryColors().setVal(false);

        for (Series s : series) {
            s.addToChart(lineChart);
        }
View Full Code Here

Examples of org.openxmlformats.schemas.drawingml.x2006.chart.CTPlotArea

        if (!(chart instanceof XSSFChart)) {
            throw new IllegalArgumentException("Chart must be instance of XSSFChart");
        }

        XSSFChart xssfChart = (XSSFChart) chart;
        CTPlotArea plotArea = xssfChart.getCTChart().getPlotArea();
        CTScatterChart scatterChart = plotArea.addNewScatterChart();
        addStyle(scatterChart);

        for (Series s : series) {
            s.addToChart(scatterChart);
        }
View Full Code Here

Examples of org.openxmlformats.schemas.drawingml.x2006.chart.CTPlotArea

  /**
   * Create a new SpreadsheetML manual layout for chart.
   * @param chart a chart to create layout for.
   */
  public XSSFManualLayout(XSSFChart chart) {
    CTPlotArea ctPlotArea = chart.getCTChart().getPlotArea();
    CTLayout ctLayout = ctPlotArea.isSetLayout() ?
      ctPlotArea.getLayout() : ctPlotArea.addNewLayout();

    initLayout(ctLayout);
  }
View Full Code Here

Examples of org.openxmlformats.schemas.drawingml.x2006.chart.CTPlotArea

  if (!(chart instanceof XSSFChart)) {
      throw new IllegalArgumentException("Chart must be instance of XSSFChart");
  }

  XSSFChart xssfChart = (XSSFChart) chart;
  CTPlotArea plotArea = xssfChart.getCTChart().getPlotArea();
  CTScatterChart scatterChart = plotArea.addNewScatterChart();
  addStyle(scatterChart);

  for (Serie s : series) {
      s.addToChart(scatterChart);
  }
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.