Refactoring report writing to own classes and using QT's XML classes for XML output. This also fixes the ticket ##408 (GUI generates invalid xml). https://sourceforge.net/apps/trac/cppcheck/ticket/408