android Textview顯示下劃線的兩種方法

  1. 在資源文件裏的寫法

<string name="key"><u>content</u></string>

spa

2.在代碼中的寫法
TextView textView = (TextView)findViewById(R.id.testView);   
textView.setText(Html.fromHtml("<u>"+"content"+"</u>"));  
資源

相關文章
相關標籤/搜索