diff --git a/PyTeX/format/formatting_config.py b/PyTeX/format/formatting_config.py index c3e734a..38afef3 100644 --- a/PyTeX/format/formatting_config.py +++ b/PyTeX/format/formatting_config.py @@ -30,6 +30,8 @@ class FormattingConfig(Config): self._include_ins: Optional[bool] = True self._use_docstrip_guards: Optional[List[str]] = None + self._escape_character: Optional[str] = None + def merge_with(self, other, strict: bool = False): """ Merges the other config into this one @@ -182,6 +184,13 @@ class FormattingConfig(Config): else: return self._use_docstrip_guards + @property + def escape_character(self) -> str: + if self._escape_character is None: + return '!' + else: + return self._escape_character + class DocFormattingConfig: def __init__(self):