ankidroid/Anki-Android — pull request #405 by ospalh (2014-06-25 12:19:36+00:00)
Title: Fix type answer clean up

Once more, do something about the typing comparison swallowing html tags.
This one is much closer to the way Anki desktop does it.
* Strip HTML from the correct answer
* Unescape “<” &c. there
* Compare to the typed answer
* Re-escape HTML before display.
* Espace “\” by hand, as the are not shown otherwise.

Whitespace is treated differently then on Anki desktop. Trailing whitespace is deliberately trimmed, as some (OK, my) software keyboards add random trailing spaces.

What is different on Anki desktop, too, is that that program moves around the `hr` between “question” and “answer” side. I think that code is a bit silly and did not copy it for AnkiDroid.