Android SDK: Set dashed underline for a word
I’ve already implemented some spanning using existing ForegroundColorSpan and BackgroundColorSpan. Now, I need to select a word via dashed underline. I googled it up and found an example: How do I make a dotted/dashed line in Android?
However, they apply the span to a whole TextView instead of a selection. I tried to use layout.getSelectionPath() and it seems I misunderstood how this method works since I don’t see the span to be applied.
This is how I tried to implement it: