我创建了一个文本视图。其中涉及到各种语言的字符。一些字符出现在文本视图的某些位置,但并不出现在其他位置。可能的原因是什么。
我创建了一个文本视图。其中涉及到各种语言的字符。一些字符出现在文本视图的某些位置,但并不出现在其他位置。可能的原因是什么。
Adding the Unicode character within java to the String in the XML file:
String str = "\u00A9" + getContext().getString(R.string.your_string);
Entering the text as HTML in java:
yourTextView.setText(Html.fromHtml("your chars");
试试这个,我希望它能起作用。
myTextView.setText(Html.fromHtml("your_string"));
strings.xml
吗?还是直接在代码中插入? - Oli