add utf8 input back to latex

This was what we originally had in templates in Anki 1. It was changed to
utf8x at one point, then we discovered that some LaTeX installs didn't have
that package so it was removed, when we should have reverted to utf8 instead.
This fixes things like umlauts but does not allow display of things like
Japanese text.
we do need to quote when adding media

contrary to commit 3576475, we do need to quote when adding media on windows
as well, as it seems webkit can not handle all representations variants when
passed unicode

as we're stripping # and % when adding characters, hopefully that's the last
of it!
pass enter back to qwidget so add tags dialog can close on enter
we shouldn't be quoting sound tags
remember tags when add cards window opened (#632)
merge 'limit to tags' and 'cram' custom study optionts (#584)
automatically resync media, and don't send media server already has (#583)
fix unit test