【发布时间】:2015-08-16 09:37:09
【问题描述】:
如何在 Android 中将百分比符号设置为带一位小数的 TextView? 我尝试过使用 unicode 符号,但它不起作用。
textES.setText(String.format("%.1f \u0025",percentage));
【问题讨论】:
如何在 Android 中将百分比符号设置为带一位小数的 TextView? 我尝试过使用 unicode 符号,但它不起作用。
textES.setText(String.format("%.1f \u0025",percentage));
【问题讨论】:
你试过了吗?
textES.setText(String.format("%.1f",percentage) + "%");
【讨论】: