本文整理汇总了C#中ZedGraph.ZedGraphControl.ZoomOutAll方法的典型用法代码示例。如果您正苦于以下问题:C# ZedGraphControl.ZoomOutAll方法的具体用法?C# ZedGraphControl.ZoomOutAll怎么用?C# ZedGraphControl.ZoomOutAll使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ZedGraph.ZedGraphControl
的用法示例。
在下文中一共展示了ZedGraphControl.ZoomOutAll方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: CreateGraph
private void CreateGraph(ZedGraphControl zg1, string[] labels, double[] values)
{
// get a reference to the GraphPane
GraphPane myPane = zg1.GraphPane;
// Set the Titles
myPane.Title = "My Test Bar Graph";
myPane.XAxis.Title = "Label";
myPane.YAxis.Title = "My Y Axis";
myPane.CurveList.Clear();
// Generate a red bar with "Curve 1" in the legend
BarItem myBar = myPane.AddBar("Hits", null, values, Color.Red);
myBar.Bar.Fill = new Fill(Color.Red, Color.White, Color.Red);
// Set the XAxis labels
myPane.XAxis.Scale.TextLabels = labels;
myPane.XAxis.Type = AxisType.Text;
// Tell ZedGraph to refigure the
// axes since the data have changed
zg1.AxisChange();
zg1.ZoomOutAll(myPane);
}
示例2: chart1_ZoomEvent
private void chart1_ZoomEvent(ZedGraphControl sender, ZoomState oldState, ZoomState newState)
{
if (mouseDownLoc.IsEmpty || mouseUpLoc.IsEmpty)
{
return;
}
// if zoom rectangle is drawn from right to left, clear all zooming
if (mouseDownLoc.X > mouseUpLoc.X && mouseDownLoc.Y > mouseUpLoc.Y )
{
sender.ZoomOutAll(sender.GraphPane);
RefreshChart(sender);
}
}