[optimize][label] support label rotate

This commit is contained in:
monitor1394
2022-04-19 13:30:24 +08:00
parent dfa978afe0
commit f11ee84517
5 changed files with 38 additions and 6 deletions

View File

@@ -27,12 +27,12 @@ namespace XCharts.Runtime
m_ReleaseDic.Remove(element.GetInstanceID());
element.name = name;
element.transform.SetParent(parent);
element.transform.localEulerAngles = new Vector3(0, 0, label.textStyle.rotate);
var text = new ChartText(element);
text.SetColor(color);
text.SetFontAndSizeAndStyle(label.textStyle, theme.common);
ChartHelper.SetActive(element, true);
}
element.transform.localEulerAngles = new Vector3(0, 0, label.rotate);
return element;
}