Add support in Settings for customising the escapeMarkup function

fixes #49