mirror of
https://github.com/XCharts-Team/XCharts.git
synced 2026-05-30 05:08:48 +00:00
修复AxisLabel在数据都是小于1的浮点数时显示Label格式不对的问题
This commit is contained in:
@@ -66,6 +66,7 @@ slug: /changelog
|
|||||||
|
|
||||||
## master
|
## master
|
||||||
|
|
||||||
|
* (2023.05.04) 修复`AxisLabel`在数据都是小于1的浮点数时显示`Label`格式不对的问题
|
||||||
* (2023.05.04) 修复`Theme`在修改默认主题的参数后运行被重置的问题
|
* (2023.05.04) 修复`Theme`在修改默认主题的参数后运行被重置的问题
|
||||||
* (2023.05.04) 增加`Symbol`选择`Custom`类型时的`Warning`提示
|
* (2023.05.04) 增加`Symbol`选择`Custom`类型时的`Warning`提示
|
||||||
* (2023.04.15) 修复`DataZoom`在多个图表时可能异常的问题 (#252)
|
* (2023.04.15) 修复`DataZoom`在多个图表时可能异常的问题 (#252)
|
||||||
|
|||||||
@@ -39,6 +39,8 @@ namespace XCharts.Runtime
|
|||||||
|
|
||||||
public static bool IsInteger(double value)
|
public static bool IsInteger(double value)
|
||||||
{
|
{
|
||||||
|
if (value == 0) return true;
|
||||||
|
if (value >= -1 && value <= 1) return false;
|
||||||
return Math.Abs(value % 1) <= (Double.Epsilon * 100);
|
return Math.Abs(value % 1) <= (Double.Epsilon * 100);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user