1.在string.xml文件中:
<string name="tips_all"><Data><![CDATA[清理进程:<font color="#7700ff00"><b>%1$d<br/></b></font>清理内存:<font color="#7700ff00"><b>%2$sMB</b></font>]]></Data></string>
2. 代码中设置textView内容
textView.setText(Html.fromHtml(String.format(getResources().getString(R.string.tips_all),process,memory+"" )));
效果图