mirror of
https://github.com/XCharts-Team/XCharts.git
synced 2026-05-17 14:00:12 +00:00
优化自定义绘制回调接口
This commit is contained in:
@@ -24,7 +24,13 @@ namespace XCharts.Examples
|
||||
|
||||
chart.onCustomDraw = delegate (VertexHelper vh)
|
||||
{
|
||||
var dataPoints = chart.series.list[0].dataPoints;
|
||||
};
|
||||
|
||||
// or
|
||||
chart.onCustomDrawSerie = delegate (VertexHelper vh, Serie serie)
|
||||
{
|
||||
if (serie.index != 0) return;
|
||||
var dataPoints = serie.dataPoints;
|
||||
if (dataPoints.Count > 0)
|
||||
{
|
||||
var pos = dataPoints[3];
|
||||
@@ -35,6 +41,11 @@ namespace XCharts.Examples
|
||||
UGL.DrawCricle(vh, pos, 5, Color.blue);
|
||||
}
|
||||
};
|
||||
|
||||
// or
|
||||
chart.onCustomDrawTop = delegate (VertexHelper vh)
|
||||
{
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user