Fix CMake version detection to handle dirty tags ("v0.5.2-dirty")

Uncommitted changes directly on a tagged version omit the commit # &
SHA1.
Attempt to report JSON strings in test output when two objects mis-match

Improves upon the existing reported string of "[Object object]". If the
object being serialised has recursive structures, the report string will
fall back to the previous implementation.
Fix direct cursor styling behaviour

Recent changes to Formatting.getAppliedStyles return type were not correctly
spread through the DirectFormattingController. Update the CC types and fix
incorrect type usages in this controller.

To help preserve future sanity, some rough unit tests have been added for
the specifically fixed branches ONLY.

Fixes #723.
Merge pull request #747 from peitschie/split-p-style-props

Fix direct cursor styling behaviour
Fix missing quotes around draw:master-page-name values used in CSS rules
Use consistently double-quotes to quote ODF style names etc. in CSS rules