I have this HTML string input which is output from Html.toHtml(EditText.getSpanned())
<font color="#000000"><font face="DEFAULT">foo</font></font>
<font color ="#4149b6"><font face="AlexBrush-Regular">baa</font></font>
I'd like to use regex to remove some HTML tags (simplify it) so that the output is:
<font color="#000000" face="DEFAULT">a</font>
<font color ="#4149b6" face="AlexBrush-Regular">b</font>
Can anyone suggest how to do this with regex or any string replacement function ?
This is the string pre-processing before using Jsoup to parse the html.
I just want the value of the attr (color/face) of font tag