Package org.jfree.chart

Examples of org.jfree.chart.JFreeChart.removeLegend()


                addTrendLine(chart,
                             XYDataSourceTrendLine.getRegressionLine(src));
        }

        if (data.numCols() == 2)
            chart.removeLegend();

        return chart;
    }

    private void addTrendLine(JFreeChart chart, XYDataset dataset) {
View Full Code Here


                t.setFont(t.getFont().deriveFont(fontSize));
            } catch (Exception tfe) {}
        }

        if (chromeless || parameters.get("hideLegend") != null)
            chart.removeLegend();
        else {
            LegendTitle l = chart.getLegend();
            String legendFontSize = getSetting("legendFontSize");
            if (l != null && legendFontSize != null) try {
                float fontSize = Float.parseFloat(legendFontSize);
View Full Code Here

        plot.setNoDataMessage(TaskScheduleDialog.resources
                .getString("Chart.No_Data_Message"));

        // create a chart and a chart panel
        JFreeChart chart = new JFreeChart(plot);
        chart.removeLegend();
        ChartPanel chartPanel = new ChartPanel(chart);
        chartPanel.setInitialDelay(50);
        chartPanel.setDismissDelay(60000);
        chartPanel.setMinimumDrawHeight(40);
        chartPanel.setMinimumDrawWidth(40);
View Full Code Here

        if (width > medium_window_width)      style = FULL;
        else if (width > short_window_widthstyle = MED;
        else                                  style = SHORT;

        JFreeChart chart = getChart();
        chart.removeLegend();
        if (style == FULL) chart.addLegend(legend);
       
        adjustAxis(chart.getXYPlot().getRangeAxis(),
                   style != FULL,
                   yLabel);
View Full Code Here

    legend.setMargin(new RectangleInsets(5, 5, 5, 5));
    legend.setFrame(new BlockBorder(Color.red));
    legend.setPadding(new RectangleInsets(10, 10, 10, 10));
    legend.setStripWidth(10);
    legend.setPosition(RectangleEdge.BOTTOM);
    chart.removeLegend();
    chart.addSubtitle(legend);
    chart.setBackgroundPaint(new GradientPaint(0, 0, Color.WHITE, 0, 1000,
        Color.WHITE));
    ChartUtilities.applyCurrentTheme(chart);
View Full Code Here

            range.setTickLabelsVisible(false);
        }
       
        XYPlot plot = new XYPlot(serieses, domain, range, new XYLineAndShapeRenderer(true, false));
        JFreeChart chart = new JFreeChart(plot);
        chart.removeLegend();

        if (width < SMALL_PIC || height < SMALL_PIC) {
        } else {
            chart.setTitle(new TextTitle(this.toString(), new Font("Arial", 0, 12)));
        }
View Full Code Here

            range.setTickLabelsVisible(false);
        }
       
        XYPlot plot = new XYPlot(serieses, domain, range, new XYLineAndShapeRenderer(true, false));
        JFreeChart chart = new JFreeChart(plot);
        chart.removeLegend();

        if (width < SMALL_PIC || height < SMALL_PIC) {
        } else {
            chart.setTitle(new TextTitle(this.toString(), new Font("Arial", 0, 12)));
        }
View Full Code Here

      XYPlot plot = new XYPlot(dataset, xAxis, yAxis, renderer);
      plot.setBackgroundPaint(Color.lightGray);
      plot.setDomainGridlinesVisible(false);
      plot.setRangeGridlinePaint(Color.white);
      JFreeChart chart = new JFreeChart("XYBlockChartDemo1", plot);
      chart.removeLegend();
      chart.setBackgroundPaint(Color.white);
      return chart;
   }

   private static XYZDataset createDataset()
View Full Code Here

      XYPlot plot = new XYPlot(dataset, xAxis, yAxis, renderer);
      plot.setBackgroundPaint(Color.lightGray);
      plot.setDomainGridlinesVisible(false);
      plot.setRangeGridlinePaint(Color.white);
      JFreeChart chart = new JFreeChart(title, plot);
      chart.removeLegend();
      chart.setBackgroundPaint(Color.white);
      return chart;
   }

   public static JFreeChart createXYLineChart(String title, String xAxisLabel, String yAxisLabel,
View Full Code Here

    chart.setTitle(title);
    TextTitle subTitle =new TextTitle(subName,new Font("Arial", Font.PLAIN, 12 ),Color.decode("#000000"), RectangleEdge.TOP, HorizontalAlignment.CENTER, VerticalAlignment.TOP, RectangleInsets.ZERO_INSETS);
    chart.addSubtitle(subTitle);
    TextTitle subTitle2 =new TextTitle(subName,new Font("Arial", Font.PLAIN, 8 ),Color.decode("#FFFFFF"), RectangleEdge.TOP, HorizontalAlignment.CENTER, VerticalAlignment.TOP, RectangleInsets.ZERO_INSETS);
    chart.addSubtitle(subTitle2);
    chart.removeLegend();
   
    chart.setBackgroundPaint(Color.white);
    logger.debug("OUT");
    return chart;
  }
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.