开发者

I want to detect new line from the text view.

How can I detect new lin开发者_Python百科e character from the text view in android?


I'm not sure if I understand your question completely but you could always get the contents of the TextView using it's getText() method then use the String methods such as contains("\n") or replace("\n", "<new stuff>") to check for new lines and process it. Then you can just set the text in the TextView to the new string using setText().

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜