Escape the file name

Since we interpolate this in XML and use .set_markup)(), we have to
escape '&' and '<'. This fixes broken display of file names with
these characters.
Better exception logging
Generate a directory name that mentions Virtaal
Add missing import
Move/remove imports