简体   繁体   English

从Java / Android中的字符串中删除下划线

[英]Remove underline from a string in Java/Android

I'm getting text input from an editText and setting it as a notification .setTitle, but when it shows in the notification, it shows up with an underline on certain words. 我从editText获取文本输入并将其设置为通知.setTitle,但是当它在通知中显示时,它会在某些单词上显示下划线。 I had no idea why, but when I went to test it, the android keyboard puts underlines under words it has auto completed. 我不知道为什么,但是当我去测试它时,安卓键盘在自动完成的单词下面加下划线。 So, what would be the best method to remove this? 那么,删除它的最佳方法是什么?

Use : 采用 :

getText().toString() 

as described here 描述在这里

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM