The bug is about custom span, .
because SpannableString implements CharSequence, but sp.substring() is different to sp.toString().substring().
Or in other words,
sp.subSequence().toString() is confusing with sp.toString().substring().
Because the implements of subSequence is not about String.
SpannableString may cause different effect sometimes, it’s strange. Always post measures to UI thread but nothing happens on screen.