I'm writing a text editor similar to QuickEdit and Turbo Editor.
However, I faced the problem that when my EditText deals with a large amount of code lines, it becomes slower and lagging.
From this question I found out that in my case I should create a custom EditText, then from this and this I suggested that I should override onDraw()
and onMeasure()
methods in it, but I didn't understand how I can apply this to EditText, and not to TextView.
Reading the sources also didn't give me the answer: I didn't find lines that possibly could improve performance of custom EditText.
Long story short: I'm looking for a way and detailed explanations on how to optimize EditText for a large amount of code lines (10 000 <).