mirror of
https://github.com/XCharts-Team/XCharts.git
synced 2026-05-18 22:40:10 +00:00
修复Tooltop的第一个ContentLabelStyle设置color无效的问题
This commit is contained in:
@@ -70,7 +70,8 @@ slug: /changelog
|
||||
|
||||
## master
|
||||
|
||||
* (2023.12.26) 增加`BorderStyle`边框样式
|
||||
* (2024.01.07) 修复`Tooltop`的第一个`ContentLabelStyle`设置`color`无效的问题
|
||||
* (2024.01.01) 增加`BorderStyle`边框样式
|
||||
* (2023.12.26) 增加`Heatmap`的`maxCache`参数支持
|
||||
* (2023.12.25) 优化`Line`开启`clip`时绘制的顶点数
|
||||
* (2023.12.22) 修复`Scatter`散点图部分边界数据不显示的问题
|
||||
|
||||
@@ -92,7 +92,7 @@ namespace XCharts.Runtime
|
||||
column.SetActive(true);
|
||||
column.SetText(param.columns[j]);
|
||||
|
||||
if (j == 0)
|
||||
if (j == 0 && ChartHelper.IsClearColor(column.text.GetColor()))
|
||||
column.text.SetColor(param.color);
|
||||
|
||||
if (j >= m_ColumnMaxWidth.Count)
|
||||
|
||||
@@ -70,7 +70,7 @@ namespace XCharts.Runtime
|
||||
#if dUI_TextMeshPro
|
||||
if (m_TMPText != null) m_TMPText.fontSize = fontSize;
|
||||
#else
|
||||
if (m_Text != null) m_Text.fontSize = (int) fontSize;
|
||||
if (m_Text != null) m_Text.fontSize = (int)fontSize;
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -104,6 +104,16 @@ namespace XCharts.Runtime
|
||||
#endif
|
||||
}
|
||||
|
||||
public Color GetColor()
|
||||
{
|
||||
#if dUI_TextMeshPro
|
||||
if (m_TMPText != null) return m_TMPText.color;
|
||||
#else
|
||||
if (m_Text != null) return m_Text.color;
|
||||
#endif
|
||||
return Color.clear;
|
||||
}
|
||||
|
||||
public void SetLineSpacing(float lineSpacing)
|
||||
{
|
||||
#if dUI_TextMeshPro
|
||||
|
||||
@@ -1067,7 +1067,7 @@ namespace XUGL
|
||||
false, smoothness, false);
|
||||
if (borderWidth > 0)
|
||||
{
|
||||
UGL.DrawBorder(vh, rect, borderWidth, borderColor, rotate, cornerRadius);
|
||||
UGL.DrawBorder(vh, rect, borderWidth, borderColor, rotate, cornerRadius, true, smoothness);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user