[optimize][axis] support auto float min-max range

This commit is contained in:
monitor1394
2022-07-11 07:04:34 +08:00
parent 69243b7cd0
commit e42afe8d47
9 changed files with 27 additions and 30 deletions

View File

@@ -103,7 +103,7 @@ namespace XCharts.Runtime
[SerializeField] private bool m_Indicator = true;
[SerializeField] private PositionType m_PositionType = PositionType.Vertice;
[SerializeField] private float m_IndicatorGap = 10;
[SerializeField] private int m_CeilRate = 0;
[SerializeField] private double m_CeilRate = 0;
[SerializeField] private bool m_IsAxisTooltip;
[SerializeField] private Color32 m_OutRangeColor = Color.red;
[SerializeField] private bool m_ConnectCenter = false;
@@ -214,7 +214,7 @@ namespace XCharts.Runtime
/// The ratio of maximum and minimum values rounded upward. The default is 0, which is automatically calculated.
/// |最大最小值向上取整的倍率。默认为0时自动计算。
/// </summary>
public int ceilRate
public double ceilRate
{
get { return m_CeilRate; }
set { if (PropertyUtil.SetStruct(ref m_CeilRate, value < 0 ? 0 : value)) SetAllDirty(); }