* UILineChart: 自定义X轴坐标时,点数据提示显示为原始值

This commit is contained in:
Sunny 2023-03-26 10:06:11 +08:00
parent b31cd59f58
commit a1b2ebde3f

View File

@ -40,6 +40,7 @@
* 2022-07-30: V3.2.2 AxisLabel.DateTimeFormat
* 2022-08-17: V3.2.3 Nan时绘制出错
* 2022-09-19: V3.2.4 MouseZoom
* 2023-03-26: V3.3.3 X轴坐标时
******************************************************************************/
using System;
@ -839,12 +840,12 @@ namespace Sunny.UI
sb.Append(Option.XAxis.Name + ": ");
string customlabel = "";
if (Option.XAxis.HaveCustomLabels)
{
int ci = (int)point.X;
customlabel = Option.XAxis.CustomLabels.GetLabel(ci);
sb.Append(customlabel);
}
//if (Option.XAxis.HaveCustomLabels)
//{
// int ci = (int)((point.X - Option.XAxis.CustomLabels.Start) / Option.XAxis.CustomLabels.Interval);
// customlabel = Option.XAxis.CustomLabels.GetLabel(ci);
// sb.Append(customlabel);
//}
if (customlabel.IsNullOrEmpty())
{