TextView is a very common view component in Android that allows to display text to user. And sometimes you want to style for text like coloring, underlying,… but not the whole text. Yes, you only want to decorate a part of text in TextView. That means your TextView maybe have multiple styles inside.
In the early days as an Android developer, I implemented multiple styles TextView in a funny way. I used multiple TextView for each style. That could get your tasks done somehow but only for short text. If you want to decorate words or sentences in a paragraph by this way, you’ll fail.
Android SDK provides SpannableString to help you style a part of text in an TextView. But this time you face a problem (or not if you see it fine) that is you need to create Span for every single text you want to decorate. You maybe end up with duplicated code. That’s why I create text-decorator to ease your work. All you need is indicating the text you want to style and choose a style for it and boom… you have what you need.
You can check https://github.com/nntuyen/text-decorator for usage.