优化Axis的数值Label的默认显示格式

This commit is contained in:
monitor1394
2023-02-10 13:23:38 +08:00
parent d6630ef5bf
commit 80d9087084
7 changed files with 69 additions and 65 deletions

View File

@@ -827,18 +827,18 @@ namespace XCharts.Runtime
return logBaseE ? (float) Math.Log(value) : (float) Math.Log(value, logBase);
}
public int GetLogMinIndex()
public double GetLogMinIndex()
{
return logBaseE ?
(int) Math.Log(context.minValue) :
(int) Math.Log(context.minValue, logBase);
Math.Log(context.minValue) :
Math.Log(context.minValue, logBase);
}
public int GetLogMaxIndex()
public double GetLogMaxIndex()
{
return logBaseE ?
(int) Math.Log(context.maxValue) :
(int) Math.Log(context.maxValue, logBase);
Math.Log(context.maxValue) :
Math.Log(context.maxValue, logBase);
}
public double GetLabelValue(int index)