This seems like a trivial problem, but is has me kind of stumped. I want to load an HTML string using Html.fromHtml(), and have any links in the string to be clickable and open in the browser.
Basic example:
textView.setText(Html.fromHtml("<a href="http://www.google.com">This is a link</a>"));
With this snippet, the text is formatted as if it were a link (blue, underlined), but it's not clickable. I tried Linkify, but it only seems to work with links that are not HTML-based.
Any suggestions?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…