I want to implement a function,
EditText user when entering text, you can make changes in accordance with the set font size,
For example, Google Docs of Office,

Now I have found a SpannableString method, but some examples seem unable to satisfy my needs.
int index = input.getSelectionEnd(); SpannableString spann = new SpannableString(show_input); AbsoluteSizeSpan word_size = new AbsoluteSizeSpan(18,true); spann.setSpan(word_size, 0, 1, Spanned.SPAN_EXCLUSIVE_EXCLUSIVE); input.getText().insert(index, spann);
So is there a way to provide it?
source share