ZedGraph labels

后端 未结 2 570
伪装坚强ぢ
伪装坚强ぢ 2021-01-15 06:28

In ZedGraph, how do I show text labels for each point and in the XAxis all together?

If I do

myPane.XAxis.Type = AxisType.Text;
myPane.         


        
2条回答
  •  天命终不由人
    2021-01-15 07:06

    If the axis type is text, the code below is easier to get x-coordinates of the points ;)

    for (int tPoint = 0; tPoint < curve.Points.Count; tPoint++)
    {
        TextObj text = new TextObj(curve.Points[tPoint].Y.ToString(), curve.Points[tPoint].X, curve.Points[tPoint].Y + 10);
    }
    

提交回复
热议问题