<span style="font-family: Arial,Helvetica,sans-serif;"><resources></span>
<string name="s1">\"双引号\"</string> <string name="s2">string:%1$s</string> <string name="s3">int:%1$d</string> <string name="s4">float:%1$2.2f</string> <string name="s5">混合:name:%1$s,age:%2$d,pai:%3$2.3f</string> </resources>
tv.setText(getString(R.string.s5,"zhangsan",2,3.8));
主要是strings.xml里面的格式
原文链接:https://www.f2er.com/xml/294784.html