mirror of
https://github.com/XCharts-Team/XCharts.git
synced 2026-05-24 18:00:26 +00:00
增加Pie和Radar的gridIndex支持设置指定网格
This commit is contained in:
@@ -621,7 +621,8 @@ namespace XCharts.Runtime
|
||||
var startY = grid.context.y + xAxis.offset;
|
||||
if (xAxis.IsTop())
|
||||
startY += grid.context.height;
|
||||
else if (xAxis.axisLine.onZero && relativedAxis.IsValue() && relativedAxis.gridIndex == xAxis.gridIndex)
|
||||
else if (xAxis.axisLine.onZero && relativedAxis != null && relativedAxis.IsValue()
|
||||
&& relativedAxis.gridIndex == xAxis.gridIndex)
|
||||
startY += relativedAxis.context.offset;
|
||||
return startY;
|
||||
}
|
||||
@@ -631,7 +632,8 @@ namespace XCharts.Runtime
|
||||
var startX = grid.context.x + yAxis.offset;
|
||||
if (yAxis.IsRight())
|
||||
startX += grid.context.width;
|
||||
else if (yAxis.axisLine.onZero && relativedAxis.IsValue() && relativedAxis.gridIndex == yAxis.gridIndex)
|
||||
else if (yAxis.axisLine.onZero && relativedAxis != null && relativedAxis.IsValue()
|
||||
&& relativedAxis.gridIndex == yAxis.gridIndex)
|
||||
startX += relativedAxis.context.offset;
|
||||
return startX;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user