I want to get the number of lines of a text view
textView.setText(\"Test line 1 Test line 2 Test line 3 Test line 4 Test line 5.............\")
I was able to get getLineCount() to not return 0 using a post, like this:
getLineCount()
post
textview.setText(“Some text”); textview.post(new Runnable() { @Override public void run() { int lineCount = textview.getLineCount(); // Use lineCount here } });