Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PieChart 中的 Legend ,使用 LabelStyle Formatter 显示 {d} 百分比 数值错误。 #304

Closed
paploli opened this issue Feb 5, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@paploli
Copy link

paploli commented Feb 5, 2024

3.9和3.10都有这个问题。

默认PieChart,Legend 的 LabelStyle Formatter 使用 {b} | {d}% | {c},其他设置保持默认
default
使用下面语句赋值

private void Start()
{
    chart.UpdateData(0, 0, 1);
    chart.UpdateData(0, 1, 1);
    chart.UpdateData(0, 2, 1);
}

error

{d}百分比数值错误,但是在Inspector修改SerieData,就不会出现这个问题。

通过检查,禁用Serie的Animation下的对应选项,即可避免错误。Change=>UpdateData,Addition=>AddData

fix

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants