Automatically enable escaping when outputting PangoMarkup

Also add quite a few self tests.

Resolves: https://bugzilla.gnome.org/show_bug.cgi?id=712256