aboutsummaryrefslogtreecommitdiff
path: root/scripts/coverage-summary.py
diff options
context:
space:
mode:
authorCraig Jennings <c@cjennings.net>2026-05-26 17:10:55 -0500
committerCraig Jennings <c@cjennings.net>2026-05-26 18:09:28 -0500
commit5c8d908a943470e3e4738c090cf8eaa1deee5a1f (patch)
tree2c5d4d7d390013b32768321389dce6419191715b /scripts/coverage-summary.py
parent1338b2ae757b7143fe4d211fc5a354c73cee526b (diff)
downloadorg-drill-5c8d908a943470e3e4738c090cf8eaa1deee5a1f.tar.gz
org-drill-5c8d908a943470e3e4738c090cf8eaa1deee5a1f.zip
fix: scope cloze fontification to drill buffers via org-drill-mode
org-drill-add-cloze-fontification ran on org-font-lock-set-keywords-hook, which fires in every org buffer, and pushed the cloze rule into org's global org-font-lock-extra-keywords. The cloze regexp is built from the [ and ] delimiters, so an org priority cookie like [#A] matched the cloze pattern and got fontified as a cloze in every org buffer, colliding with org's headline fontification and stripping the heading's org-level-N face. I replaced the global install with org-drill-mode, a buffer-local minor mode that adds the cloze keywords only to its own buffer via font-lock-add-keywords. org-drill-auto-enable-mode (default on) turns the mode on from org-mode-hook in buffers that hold drill cards, so existing drill files keep their cloze highlighting while plain org buffers stay clean. Highlighting still respects org-drill-use-visible-cloze-face-p. The cloze regexp itself is unchanged, so the single-line cloze constraint from #38 is preserved.
Diffstat (limited to 'scripts/coverage-summary.py')
0 files changed, 0 insertions, 0 deletions