Android-RTEditor
Android-RTEditor copied to clipboard
IndexOutOfBoundsException
Hi!
I encountered a very strange issue.
E/UncaughtException: java.lang.IndexOutOfBoundsException: getChars (-1 ... 46) starts before 0
at android.text.SpannableStringBuilder.checkRange(SpannableStringBuilder.java:1270)
at android.text.SpannableStringBuilder.getChars(SpannableStringBuilder.java:1147)
at android.text.TextUtils.getChars(TextUtils.java:89)
at android.text.TextUtils.substring(TextUtils.java:280)
at android.view.inputmethod.BaseInputConnection.getSelectedText(BaseInputConnection.java:531)
at com.android.internal.view.IInputConnectionWrapper.executeMessage(IInputConnectionWrapper.java:308)
at com.android.internal.view.IInputConnectionWrapper$MyHandler.handleMessage(IInputConnectionWrapper.java:93)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:154)
at android.app.ActivityThread.main(ActivityThread.java:6119)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:886)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:776)
I can seem to find the issue. This happens whe the user selects all text and then clicks outside the selected text.

I tested your app on my S8 and it didn't crash at all. Cab you confirm that the issue is obsolete?