diff --git a/anki/template/template.py b/anki/template/template.py index f867db33b..3c4d4b407 100644 --- a/anki/template/template.py +++ b/anki/template/template.py @@ -4,9 +4,7 @@ from typing import Any, Callable, Dict, Pattern from anki.hooks import runFilter from anki.utils import stripHTML, stripHTMLMedia -# The (?si) flags make the regex match case-insensitively and make . match any -# character including newlines. -# See: https://docs.python.org/3/howto/regex.html#compilation-flags +# Matches a {{c123::clozed-out text::hint}} Cloze deletion, case-insensitively. clozeReg = r"(?si)\{\{(c)%s::(.*?)(::(.*?))?\}\}" modifiers: Dict[str, Callable] = {}