Examples of JFreeChart


Examples of org.jfree.chart.JFreeChart

  protected JFreeChart computeCategoryChart(final CategoryDataset dataset)
  {
    final PlotOrientation orientation = computePlotOrientation();
    if (isThreeD())
    {
      final JFreeChart chart = ChartFactory.createLineChart3D(computeTitle(), getCategoryAxisLabel(), getValueAxisLabel(), dataset,
          orientation, isShowLegend(), false, false);
      chart.getCategoryPlot().setDomainAxis(new FormattedCategoryAxis3D(getCategoryAxisLabel(),
          getCategoricalAxisMessageFormat(), getRuntime().getResourceBundleFactory().getLocale()));
      return chart;
    }
    else
    {
      final JFreeChart chart = ChartFactory.createLineChart(computeTitle(), getCategoryAxisLabel(), getValueAxisLabel(), dataset,
          orientation, isShowLegend(), false, false);
      chart.getCategoryPlot().setDomainAxis(new FormattedCategoryAxis(getCategoryAxisLabel(),
          getCategoricalAxisMessageFormat(), getRuntime().getResourceBundleFactory().getLocale()));
      return chart;
    }
  }
View Full Code Here

Examples of org.jfree.chart.JFreeChart

  }


  protected JFreeChart computeXYChart(final XYDataset xyDataset)
  {
    final JFreeChart chart;
    if (xyDataset instanceof TimeSeriesCollection)
    {

      if (isStacked())
      {
        final ExtTimeTableXYDataset tableXYDataset = convertToTable(xyDataset);
        chart = createTimeSeriesChart(computeTitle(), getDomainTitle(), getRangeTitle(), tableXYDataset,
            isShowLegend(), false, false, isStacked());
      }
      else
      {
        chart = createTimeSeriesChart(computeTitle(), getDomainTitle(), getRangeTitle(), xyDataset,
            isShowLegend(), false, false, isStacked());
      }
    }
    else
    {
      final PlotOrientation orientation = computePlotOrientation();
      if (isStacked())
      {
        chart = createStackedXYAreaChart(computeTitle(), getDomainTitle(), getRangeTitle(),
            xyDataset, orientation, isShowLegend(), false, false);
      }
      else
      {
        chart = ChartFactory.createXYAreaChart(computeTitle(), getDomainTitle(), getRangeTitle(),
            xyDataset, orientation, isShowLegend(), false, false);
      }
    }

    configureLogarithmicAxis(chart.getXYPlot());
    configureLineChart(chart.getXYPlot());
    return chart;
  }
View Full Code Here

Examples of org.jfree.chart.JFreeChart

    }
    renderer.setBaseToolTipGenerator(toolTipGenerator);
    renderer.setURLGenerator(urlGenerator);
    plot.setRenderer(renderer);

    return new JFreeChart(title, JFreeChart.DEFAULT_TITLE_FONT, plot, legend);
  }
View Full Code Here

Examples of org.jfree.chart.JFreeChart

    return new JFreeChart(title, JFreeChart.DEFAULT_TITLE_FONT, plot, legend);
  }

  protected JFreeChart computeXYChart(final XYDataset xyDataset)
  {
    final JFreeChart chart;
    if (xyDataset instanceof TimeSeriesCollection)
    {

      if (isStacked())
      {
        final ExtTimeTableXYDataset tableXYDataset = convertToTable(xyDataset);
        chart = createTimeSeriesChart(computeTitle(), getDomainTitle(), getRangeTitle(), tableXYDataset,
            isShowLegend(), false, false, isStacked());
      }
      else
      {
        chart = createTimeSeriesChart(computeTitle(), getDomainTitle(), getRangeTitle(), xyDataset,
            isShowLegend(), false, false, isStacked());
      }
    }
    else
    {
      final PlotOrientation orientation = computePlotOrientation();
      if (isStacked())
      {
        chart = createStackedXYAreaChart(computeTitle(), getDomainTitle(), getRangeTitle(),
            xyDataset, orientation, isShowLegend(), false, false);
      }
      else
      {
        chart = ChartFactory.createXYAreaChart(computeTitle(), getDomainTitle(), getRangeTitle(),
            xyDataset, orientation, isShowLegend(), false, false);
      }
    }

    configureLogarithmicAxis(chart.getXYPlot());
    return chart;
  }
View Full Code Here

Examples of org.jfree.chart.JFreeChart

    final XYPlot plot = new XYPlot(dataset, xAxis, yAxis, renderer);
    plot.setOrientation(orientation);

    plot.setRangeAxis(yAxis)// forces recalculation of the axis range

    return new JFreeChart(title, JFreeChart.DEFAULT_TITLE_FONT, plot, legend);
  }
View Full Code Here

Examples of org.jfree.chart.JFreeChart

  {
    super.configureChart(chart);

    final Plot plot = chart.getPlot();
    final MultiplePiePlot mpp = (MultiplePiePlot) plot;
    final JFreeChart pc = mpp.getPieChart();
    configureSubChart(pc);

    final PiePlot pp = (PiePlot) pc.getPlot();
    if (StringUtils.isEmpty(getTooltipFormula()) == false)
    {
      pp.setToolTipGenerator(new FormulaPieTooltipGenerator(getRuntime(), getTooltipFormula()));
    }
    if (StringUtils.isEmpty(getUrlFormula()) == false)
View Full Code Here

Examples of org.jfree.chart.JFreeChart

    {
      xyzDataset = null;
      maxZValue = 0;
    }

    final JFreeChart rtn = ChartFactory.createBubbleChart
        (computeTitle(), getDomainTitle(), getRangeTitle(), xyzDataset,
            computePlotOrientation(), isShowLegend(), false, false);

    final BubbleRenderer renderer = new BubbleRenderer();
    renderer.setMaxSize(getMaxBubbleSize());
    renderer.setMaxZ(maxZValue);
    rtn.getXYPlot().setRenderer(renderer);
    configureLogarithmicAxis(rtn.getXYPlot());
    return rtn;
  }
View Full Code Here

Examples of org.jfree.chart.JFreeChart

  }


  protected JFreeChart computeXYChart(final XYDataset xyDataset)
  {
    final JFreeChart chart;
    if (xyDataset instanceof TimeSeriesCollection)
    {
      chart = ChartFactory.createTimeSeriesChart(computeTitle(), getDomainTitle(), getRangeTitle(), xyDataset,
          isShowLegend(), false, false);
    }
    else
    {
      final PlotOrientation orientation = computePlotOrientation();
      chart = ChartFactory.createXYLineChart(computeTitle(), getDomainTitle(), getRangeTitle(),
          xyDataset, orientation, isShowLegend(), false, false);
    }
    configureLogarithmicAxis(chart.getXYPlot());
    return chart;
  }
View Full Code Here

Examples of org.jfree.chart.JFreeChart

            int all = DataManager.getCount(module, -1, null);
            if (total < all)
              dataset.setValue(DcResources.getText("lblEmpty") + " (" + String.valueOf(all - total) + ")" , Integer.valueOf(all - total));
           
            if (!isCanceled()) {
              JFreeChart chart = ChartFactory.createPieChart(null, dataset, true, true, false);
              chartPanel = new org.jfree.chart.ChartPanel(chart);
              chartPanel.setFont(ComponentFactory.getStandardFont());

              try {
                    SwingUtilities.invokeAndWait(new Runnable() {
View Full Code Here

Examples of org.jfree.chart.JFreeChart

            int all = DataManager.getCount(module, -1, null);
            if (total < all)
              dataset.addValue(all - total, DcResources.getText("lblEmpty"), field.getLabel());
           
            if (!isCanceled()) {
                JFreeChart chart = ChartFactory.createBarChart(
                    null, null, null, dataset, PlotOrientation.VERTICAL, true, true, false);
              chartPanel = new org.jfree.chart.ChartPanel(chart);
              chartPanel.setFont(ComponentFactory.getStandardFont());
             
                SwingUtilities.invokeLater(new Runnable() {
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.