i know highlighting in text-view is possible
Highlight Textview Using EditText
and scrolling text-view is also possible (got the scroll code from here and is successfully scrolling too) textView scroll at first line
now the question is, i am searching and i want to highlight that text and navigate to it, when someone presses the search button, the highlighting part is perfect, now i can get the index of the word in the string, but not line number of the string in the text-view,
point is if i want to find a position of certain text in text-view, i.e. which line number is that on, how to do it ?
i found an answer for this, but later i realized its for iOS Search occurrences of a string in a TextView