allowing only string-formatting html tags in the doc preview

Every other tags must be deleted because since the text is cut, it might
break the gui when the remaining text misses close tags. String
formatting tags could be useful though (for example: <sup> node in
formulas).