我想运用以下代码给textview添加一个链接:
TextView textview = (TextView) findViewById(R.id.mytext);
Pattern myPattern = Pattern.compile("WordToBeLinked");
String link = "http://mydomain.com/something";
Linkify.addLinks(textview, myPattern, link);
预期实现的正常的运行结果应该是:WordToBeLinked可以链接,根据这个链接可以打开浏览器。但不知为什么使用Linkify给WordToBeLinked添加链接到URL后, URL会被这样调用:
http://mydomain.com/somethingWordToBeLinked
是哪里出错了呢?