gpt4 book ai didi

org.jfree.chart.renderer.xy.XYAreaRenderer类的使用及代码示例

转载 作者:知者 更新时间:2024-03-23 02:33:05 26 4
gpt4 key购买 nike

本文整理了Java中org.jfree.chart.renderer.xy.XYAreaRenderer类的一些代码示例,展示了XYAreaRenderer类的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XYAreaRenderer类的具体详情如下:
包路径:org.jfree.chart.renderer.xy.XYAreaRenderer
类名称:XYAreaRenderer

XYAreaRenderer介绍

[英]Area item renderer for an XYPlot. This class can draw (a) shapes at each point, or (b) lines between points, or (c) both shapes and lines, or (d) filled areas, or (e) filled areas and shapes. The example shown here is generated by the XYAreaRendererDemo1.java program included in the JFreeChart demo collection:
[中]XYPlot的区域项渲染器。这门课可以绘制(a)每个点的形状,或(b)点之间的线,或(c)形状和线,或(d)填充区域,或(e)填充区域和形状。这里显示的示例由XYAreaRenderDemo1生成。JFreeChart演示集合中包含的java程序:

代码示例

代码示例来源:origin: jfree/jfreechart

/**
 * Returns a clone of the renderer.
 *
 * @return A clone.
 *
 * @throws CloneNotSupportedException if the renderer cannot be cloned.
 */
@Override
public Object clone() throws CloneNotSupportedException {
  return super.clone();
}

代码示例来源:origin: org.codehaus.jtstand/jtstand-chart

/**
 * Sets a flag that controls whether or not outlines of the areas are drawn
 * and sends a {@link RendererChangeEvent} to all registered listeners.
 *
 * @param show  the flag.
 *
 * @see #isOutline()
 */
public void setOutline(boolean show) {
  this.showOutline = show;
  fireChangeEvent();
}

代码示例来源:origin: jfree/jfreechart

if (!getItemVisible(series, item)) {
  return;
      plot.getRangeAxisEdge());
  if (plot.getOrientation().isVertical()) {
    moveTo(areaState.area, transX1, zero);
  } else if (plot.getOrientation().isHorizontal()) {
    moveTo(areaState.area, zero, transX1);
  lineTo(areaState.area, transX1, transY1);
} else if (plot.getOrientation().isHorizontal()) {
  lineTo(areaState.area, transY1, transX1);
Paint paint = getItemPaint(series, item);
Stroke stroke = getItemStroke(series, item);
g2.setPaint(paint);
g2.setStroke(stroke);
if (getPlotShapes()) {
  shape = getItemShape(series, item);
  if (orientation == PlotOrientation.VERTICAL) {
    shape = ShapeUtils.createTranslatedShape(shape, transX1,
if (getPlotLines()) {
  if (item > 0) {
    if (plot.getOrientation() == PlotOrientation.VERTICAL) {
if (getPlotArea() && item > 0 && item == (itemCount - 1)) {

代码示例来源:origin: jfree/jfreechart

public LegendItem getLegendItem(int datasetIndex, int series) {
  LegendItem result = null;
  XYPlot xyplot = getPlot();
  if (xyplot != null) {
    XYDataset dataset = xyplot.getDataset(datasetIndex);
    if (dataset != null) {
      XYSeriesLabelGenerator lg = getLegendItemLabelGenerator();
      String label = lg.generateLabel(dataset, series);
      String description = label;
      String toolTipText = null;
      if (getLegendItemToolTipGenerator() != null) {
        toolTipText = getLegendItemToolTipGenerator().generateLabel(
            dataset, series);
      if (getLegendItemURLGenerator() != null) {
        urlText = getLegendItemURLGenerator().generateLabel(
            dataset, series);
      Paint paint = lookupSeriesPaint(series);
      result = new LegendItem(label, description, toolTipText,
          urlText, this.legendArea, paint);
      result.setLabelFont(lookupLegendTextFont(series));
      Paint labelPaint = lookupLegendTextPaint(series);
      if (labelPaint != null) {
        result.setLabelPaint(labelPaint);

代码示例来源:origin: com.xpn.xwiki.platform/xwiki-core

renderer = new XYAreaRenderer();

代码示例来源:origin: jfree/jfreechart

/**
 * Tests the renderer for equality with an arbitrary object.
 *
 * @param obj  the object ({@code null} permitted).
 *
 * @return A boolean.
 */
@Override
public boolean equals(Object obj) {
  if (obj == this) {
    return true;
  }
  if (!(obj instanceof StackedXYAreaRenderer) || !super.equals(obj)) {
    return false;
  }
  StackedXYAreaRenderer that = (StackedXYAreaRenderer) obj;
  if (!PaintUtils.equal(this.shapePaint, that.shapePaint)) {
    return false;
  }
  if (!ObjectUtils.equal(this.shapeStroke, that.shapeStroke)) {
    return false;
  }
  return true;
}

代码示例来源:origin: org.codehaus.jtstand/jtstand-chart

if (!getItemVisible(series, item)) {
  return;
Paint paint = getItemPaint(series, item);
Stroke stroke = getItemStroke(series, item);
g2.setPaint(paint);
g2.setStroke(stroke);
if (getPlotShapes()) {
  shape = getItemShape(series, item);
  if (orientation == PlotOrientation.VERTICAL) {
    shape = ShapeUtilities.createTranslatedShape(shape, transX1,
if (getPlotLines()) {
  if (item > 0) {
    if (plot.getOrientation() == PlotOrientation.VERTICAL) {
if (getPlotArea() && item > 0 && item == (itemCount - 1)) {
    paint = lookupSeriesFillPaint(series);
  if (isOutline()) {
    Shape area = areaState.area;
    Stroke outlineStroke = lookupSeriesOutlineStroke(series);
    if (outlineStroke instanceof BasicStroke) {
      BasicStroke bs = (BasicStroke) outlineStroke;
    g2.setPaint(lookupSeriesOutlinePaint(series));

代码示例来源:origin: org.codehaus.jtstand/jtstand-chart

XYPlot xyplot = getPlot();
if (xyplot != null) {
  XYDataset dataset = xyplot.getDataset(datasetIndex);
  if (dataset != null) {
    XYSeriesLabelGenerator lg = getLegendItemLabelGenerator();
    String label = lg.generateLabel(dataset, series);
    String description = label;
    String toolTipText = null;
    if (getLegendItemToolTipGenerator() != null) {
      toolTipText = getLegendItemToolTipGenerator().generateLabel(
          dataset, series);
    if (getLegendItemURLGenerator() != null) {
      urlText = getLegendItemURLGenerator().generateLabel(
          dataset, series);
    Paint paint = lookupSeriesPaint(series);
    result = new LegendItem(label, description, toolTipText,
        urlText, this.legendArea, paint);
    result.setLabelFont(lookupLegendTextFont(series));
    Paint labelPaint = lookupLegendTextPaint(series);
    if (labelPaint != null) {
      result.setLabelPaint(labelPaint);

代码示例来源:origin: pentaho/pentaho-platform

switch ( chartDefinition.getChartType() ) {
 case AREA_CHART_TYPE:
  renderer = chartDefinition.isStacked() ? new StackedXYAreaRenderer2() : new XYAreaRenderer();
  break;
 default:

代码示例来源:origin: org.codehaus.jtstand/jtstand-chart

/**
 * Tests the renderer for equality with an arbitrary object.
 *
 * @param obj  the object (<code>null</code> permitted).
 *
 * @return A boolean.
 */
public boolean equals(Object obj) {
  if (obj == this) {
    return true;
  }
  if (!(obj instanceof StackedXYAreaRenderer) || !super.equals(obj)) {
    return false;
  }
  StackedXYAreaRenderer that = (StackedXYAreaRenderer) obj;
  if (!PaintUtilities.equal(this.shapePaint, that.shapePaint)) {
    return false;
  }
  if (!ObjectUtilities.equal(this.shapeStroke, that.shapeStroke)) {
    return false;
  }
  return true;
}

代码示例来源:origin: org.codehaus.jtstand/jtstand-chart

plot.setRenderer(new XYAreaRenderer(XYAreaRenderer.AREA, tipGenerator,
    urlGenerator));
JFreeChart chart = new JFreeChart(title, JFreeChart.DEFAULT_TITLE_FONT,

代码示例来源:origin: jfree/jfreechart

/**
 * Sets a flag that controls whether or not outlines of the areas are drawn
 * and sends a {@link RendererChangeEvent} to all registered listeners.
 *
 * @param show  the flag.
 *
 * @see #isOutline()
 */
public void setOutline(boolean show) {
  this.showOutline = show;
  fireChangeEvent();
}

代码示例来源:origin: org.codehaus.jtstand/jtstand-chart

/**
 * Returns a clone of the renderer.
 *
 * @return A clone.
 *
 * @throws CloneNotSupportedException if the renderer cannot be cloned.
 */
public Object clone() throws CloneNotSupportedException {
  return super.clone();
}

代码示例来源:origin: pentaho/pentaho-platform

break;
case AREA_CHART_TYPE:
 renderer = new XYAreaRenderer();
 break;
case STEP_CHART_TYPE:

代码示例来源:origin: jfree/jfreechart

/**
 * Sets the flag that controls whether or not the series fill paint is
 * used to fill the area under the line and sends a
 * {@link RendererChangeEvent} to all listeners.
 *
 * @param use  the new flag value.
 *
 * @since 1.0.14
 */
public void setUseFillPaint(boolean use) {
  this.useFillPaint = use;
  fireChangeEvent();
}

代码示例来源:origin: org.n52.sensorweb/sensorwebclient-api

plot.setRenderer(datasetIndex, new XYAreaRenderer());

代码示例来源:origin: org.codehaus.jtstand/jtstand-chart

/**
 * Sets the flag that controls whether or not the series fill paint is
 * used to fill the area under the line and sends a
 * {@link RendererChangeEvent} to all listeners.
 *
 * @param use  the new flag value.
 *
 * @since 1.0.14
 */
public void setUseFillPaint(boolean use) {
  this.useFillPaint = use;
  fireChangeEvent();
}

代码示例来源:origin: jfree/jfreechart

plot.setRenderer(new XYAreaRenderer(XYAreaRenderer.AREA, tipGenerator,
    urlGenerator));
JFreeChart chart = new JFreeChart(title, JFreeChart.DEFAULT_TITLE_FONT,

代码示例来源:origin: org.codehaus.jtstand/jtstand-chart

/**
 * Sets the shape used as an area in each legend item and sends a
 * {@link RendererChangeEvent} to all registered listeners.
 *
 * @param area  the area (<code>null</code> not permitted).
 */
public void setLegendArea(Shape area) {
  if (area == null) {
    throw new IllegalArgumentException("Null 'area' argument.");
  }
  this.legendArea = area;
  fireChangeEvent();
}

代码示例来源:origin: pentaho/pentaho-platform

break;
case AREA_CHART_TYPE:
 renderer = new XYAreaRenderer();
 break;
case STEP_CHART_TYPE:

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com