在绘制两条曲线后,我在 zedgraph 控件上有两条曲线......
PointPairList thresholdList = new PointPairList();
PointPairList powerList = new PointPairList();
private void plotPower()
{
// Create an object to access ZedGraph Pane
GraphPane pane = zedGraphControl1.GraphPane;
LineItem thresholdLine = new LineItem("thresholdLine");
LineItem powerLine = new LineItem("powerLine");
// Set the Threshold Limit
double thresoldLimit = Convert.ToDouble(numAnalysisThreshold2.Value);
// Points
double[] x = new double[]{0, pane.XAxis.Scale.Max};
double[] y = new double[]{thresoldLimit, thresoldLimit};
// Set the threshold line curve list
thresholdList.Add(x, y);
// Set the Power Line curve list
powerdList.Add(XData, YData);
// Add Curves
thresholdLine = pane.AddCurve("", thresholdList, Color.Red, SymbolType.None);
powerLine = pane.AddCurve("", powerList, Color.Red, SymbolType.None);
// Refresh Chart
this.Invalidate();
zedGraphControl1.Refresh();
}
从上面的代码中,我设法将两条曲线绘制为阈值线曲线上的电源线曲线。
现在我的问题是,如果我想把任何一条曲线放在前面......有没有可用的方法(例如:bringittoFront()......)......?
非常感谢您抽出宝贵的时间...... :)