[optimize][axis] optimize minor split line of time axis

This commit is contained in:
monitor1394
2022-08-09 13:38:23 +08:00
parent f1f2ea78be
commit 9981ce2d23
3 changed files with 9 additions and 1 deletions

View File

@@ -562,6 +562,12 @@ namespace XCharts
if (AxisHelper.NeedShowSplit(axis))
{
var size = AxisHelper.GetScaleNumber(axis, axisLength, dataZoom);
if (axis.IsTime())
{
size += 1;
if (!ChartHelper.IsEquals(axis.GetLastLabelValue(), axis.context.maxValue))
size += 1;
}
var tickWidth = axis.axisTick.GetWidth(theme.tickWidth);
var tickColor = axis.axisTick.GetColor(theme.tickColor);
var current = orient == Orient.Horizonal ? startX : startY;