当前位置: 首页>>代码示例>>Java>>正文


Java ChartChangeEvent类代码示例

本文整理汇总了Java中org.jfree.chart.event.ChartChangeEvent的典型用法代码示例。如果您正苦于以下问题:Java ChartChangeEvent类的具体用法?Java ChartChangeEvent怎么用?Java ChartChangeEvent使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


ChartChangeEvent类属于org.jfree.chart.event包,在下文中一共展示了ChartChangeEvent类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: getChartChangeListner

import org.jfree.chart.event.ChartChangeEvent; //导入依赖的package包/类
private ChartChangeListener getChartChangeListner() {
    return new ChartChangeListener() {
        @Override
        public void chartChanged(ChartChangeEvent event) {
            // Is weird. This works well for zoom-in. When we add new CCI or
            // RIS. This event function will be triggered too. However, the
            // returned draw area will always be the old draw area, unless
            // you move your move over.
            // Even I try to capture event.getType() == ChartChangeEventType.NEW_DATASET
            // also doesn't work.
            if (event.getType() == ChartChangeEventType.GENERAL) {
                ChartJDialog.this.chartLayerUI.updateTraceInfos();
                // Re-calculating high low value.
                ChartJDialog.this.updateHighLowJLabels();
            }
        }
    };
}
 
开发者ID:lead4good,项目名称:open-java-trade-manager,代码行数:19,代码来源:ChartJDialog.java

示例2: chartChanged

import org.jfree.chart.event.ChartChangeEvent; //导入依赖的package包/类
/**
 * Receives notification of changes to the chart (or any of its components),
 * and redraws the chart.
 *
 * @param event
 */
public void chartChanged( ChartChangeEvent event ) {

    /* 
     * Do not look at event.getSource(), since the source of the event is
     * likely to be one of the chart's components rather than the chart itself.
     */
    if ( event.getType() == ChartChangeEventType.DATASET_UPDATED ) {
        repaint();
    }
    else if ( event.getType() == ChartChangeEventType.NEW_DATASET ) {
        repaint();
    }
    else {
        updateAll();
    }
}
 
开发者ID:mleoking,项目名称:PhET,代码行数:23,代码来源:JFreeChartNode.java

示例3: chartChanged

import org.jfree.chart.event.ChartChangeEvent; //导入依赖的package包/类
/**
 * Receives notification of changes to the chart, and redraws the chart.
 * 
 * @param event
 *            details of the chart change event.
 */

@Override
public void chartChanged(ChartChangeEvent event) {
	Plot plot = this.chart.getPlot();
	if (plot instanceof Zoomable) {
		Zoomable z = (Zoomable) plot;
		this.orientation = z.getOrientation();
	}
	repaint();
}
 
开发者ID:transwarpio,项目名称:rapidminer,代码行数:17,代码来源:AbstractChartPanel.java

示例4: setNotify

import org.jfree.chart.event.ChartChangeEvent; //导入依赖的package包/类
/**
 * Sets a flag that controls whether or not listeners receive {@link ChartChangeEvent}
 * notifications.
 *
 * @param notify  a boolean.
 */
public void setNotify(boolean notify) {
    this.notify = notify;
    // if the flag is being set to true, there may be queued up changes...
    if (notify) {
        notifyListeners(new ChartChangeEvent(this));
    }
}
 
开发者ID:parabuild-ci,项目名称:parabuild-ci,代码行数:14,代码来源:JFreeChart.java

示例5: notifyListeners

import org.jfree.chart.event.ChartChangeEvent; //导入依赖的package包/类
/**
 * Sends a {@link ChartChangeEvent} to all registered listeners.
 *
 * @param event  information about the event that triggered the notification.
 */
protected void notifyListeners(ChartChangeEvent event) {

    if (this.notify) {
        Object[] listeners = this.changeListeners.getListenerList();
        for (int i = listeners.length - 2; i >= 0; i -= 2) {
            if (listeners[i] == ChartChangeListener.class) {
                ((ChartChangeListener) listeners[i + 1]).chartChanged(event);
            }
        }
    }

}
 
开发者ID:parabuild-ci,项目名称:parabuild-ci,代码行数:18,代码来源:JFreeChart.java

示例6: chartChanged

import org.jfree.chart.event.ChartChangeEvent; //导入依赖的package包/类
/**
 * Receives notification of changes to the chart, and redraws the chart.
 *
 * @param event  details of the chart change event.
 */
public void chartChanged(ChartChangeEvent event) {
    this.refreshBuffer = true;
    Plot plot = chart.getPlot();
    if (plot instanceof Zoomable) 
    {
        Zoomable z = (Zoomable) plot;
        this.orientation = z.getOrientation();
    }
    this.redraw();
}
 
开发者ID:parabuild-ci,项目名称:parabuild-ci,代码行数:16,代码来源:ChartComposite.java

示例7: chartChanged

import org.jfree.chart.event.ChartChangeEvent; //导入依赖的package包/类
/**
 * Receives notification of changes to the chart, and redraws the chart.
 *
 * @param event  details of the chart change event.
 */
public void chartChanged(ChartChangeEvent event) {
    this.refreshBuffer = true;
    Plot plot = this.chart.getPlot();
    if (plot instanceof Zoomable) {
        Zoomable z = (Zoomable) plot;
        this.orientation = z.getOrientation();
    }
    repaint();
}
 
开发者ID:parabuild-ci,项目名称:parabuild-ci,代码行数:15,代码来源:ChartPanel.java

示例8: notifyListeners

import org.jfree.chart.event.ChartChangeEvent; //导入依赖的package包/类
/**
 * Sends a {@link ChartChangeEvent} to all registered listeners.
 *
 * @param event  information about the event that triggered the 
 *               notification.
 */
protected void notifyListeners(ChartChangeEvent event) {
    if (this.notify) {
        Object[] listeners = this.changeListeners.getListenerList();
        for (int i = listeners.length - 2; i >= 0; i -= 2) {
            if (listeners[i] == ChartChangeListener.class) {
                ((ChartChangeListener) listeners[i + 1]).chartChanged(
                        event);
            }
        }
    }
}
 
开发者ID:parabuild-ci,项目名称:parabuild-ci,代码行数:18,代码来源:JFreeChart.java

示例9: chartChanged

import org.jfree.chart.event.ChartChangeEvent; //导入依赖的package包/类
/**
 * Receives notification of changes to the chart, and redraws the chart.
 *
 * @param event  details of the chart change event.
 */
public void chartChanged(ChartChangeEvent event) {
    this.refreshBuffer = true;
    Plot plot = this.chart.getPlot();
    if (plot instanceof Zoomable) {
        Zoomable z = (Zoomable) plot;
        this.orientation = z.getOrientation();
    }
    this.canvas.redraw();
}
 
开发者ID:mdzio,项目名称:ccu-historian,代码行数:15,代码来源:ChartComposite.java

示例10: chartChanged

import org.jfree.chart.event.ChartChangeEvent; //导入依赖的package包/类
/**
 * Receives notification of changes to the chart, and redraws the chart.
 *
 * @param event  details of the chart change event.
 */
@Override
public void chartChanged(ChartChangeEvent event) {
    this.refreshBuffer = true;
    Plot plot = this.chart.getPlot();
    if (plot instanceof Zoomable) {
        Zoomable z = (Zoomable) plot;
        this.orientation = z.getOrientation();
    }
    repaint();
}
 
开发者ID:mdzio,项目名称:ccu-historian,代码行数:16,代码来源:ChartPanel.java

示例11: notifyListeners

import org.jfree.chart.event.ChartChangeEvent; //导入依赖的package包/类
/**
 * Sends a {@link ChartChangeEvent} to all registered listeners.
 *
 * @param event  information about the event that triggered the
 *               notification.
 */
protected void notifyListeners(ChartChangeEvent event) {
    if (this.notify) {
        Object[] listeners = this.changeListeners.getListenerList();
        for (int i = listeners.length - 2; i >= 0; i -= 2) {
            if (listeners[i] == ChartChangeListener.class) {
                ((ChartChangeListener) listeners[i + 1]).chartChanged(
                        event);
            }
        }
    }
}
 
开发者ID:mdzio,项目名称:ccu-historian,代码行数:18,代码来源:JFreeChart.java

示例12: chartChanged

import org.jfree.chart.event.ChartChangeEvent; //导入依赖的package包/类
@Override
public void chartChanged(ChartChangeEvent e) {
       try {
           zoomRangeBounds = e.getChart().getXYPlot().getRangeAxis().getRange();
           zoomDomainBounds = e.getChart().getXYPlot().getDomainAxis().getRange();
           useZoomBounds.setSelected(true);
       } catch (Exception e1) {
           e1.printStackTrace();
       }
   }
 
开发者ID:Matsemann,项目名称:eamaster,代码行数:11,代码来源:ApproximationSetViewer.java

示例13: chartChanged

import org.jfree.chart.event.ChartChangeEvent; //导入依赖的package包/类
@Override
public void chartChanged(ChartChangeEvent event) {
    JFreeChart chart = event.getChart();
    if (chart != null) {
        renderToSvg(chart);
    }
}
 
开发者ID:Matsemann,项目名称:eamaster,代码行数:8,代码来源:PlotSaver.java

示例14: chartChanged

import org.jfree.chart.event.ChartChangeEvent; //导入依赖的package包/类
/**
 * Receives notification of changes to the chart, and redraws the chart.
 *
 * @param event  details of the chart change event.
 */
public void chartChanged(ChartChangeEvent event) {
    this.refreshBuffer = true;
    Plot plot = chart.getPlot();
    if (plot instanceof Zoomable) {
        Zoomable z = (Zoomable) plot;
        this.orientation = z.getOrientation();
    }
    repaint();
}
 
开发者ID:opensim-org,项目名称:opensim-gui,代码行数:15,代码来源:ChartPanel.java

示例15: setPadding

import org.jfree.chart.event.ChartChangeEvent; //导入依赖的package包/类
/**
 * Sets the padding between the chart border and the chart drawing area,
 * and sends a {@link ChartChangeEvent} to all registered listeners.
 * 
 * @param padding  the padding (<code>null</code> not permitted).
 */
public void setPadding(RectangleInsets padding) {
    if (padding == null) {
        throw new IllegalArgumentException("Null 'padding' argument.");   
    }
    this.padding = padding;
    notifyListeners(new ChartChangeEvent(this));
}
 
开发者ID:opensim-org,项目名称:opensim-gui,代码行数:14,代码来源:JFreeChart.java


注:本文中的org.jfree.chart.event.ChartChangeEvent类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。