]> git.eshelyaron.com Git - emacs.git/commit
Fix string fontification for tree-sitter python-mode
authorYuan Fu <casouri@gmail.com>
Tue, 1 Nov 2022 20:26:16 +0000 (13:26 -0700)
committerYuan Fu <casouri@gmail.com>
Tue, 1 Nov 2022 20:26:16 +0000 (13:26 -0700)
commit50e33639fe190f0a1c47b8e4c0fcc4735cb60909
tree5c4e00c02b1c974812a6173a5fdee88376731397
parentccd2509ed31f953408240357e9b84c3d3b3f6a2b
Fix string fontification for tree-sitter python-mode

Now when user inserts a ending quote, the whole string is ganranteed
to be refontified and redisplayed.

* lisp/progmodes/python.el (python--treesit-fontify-string): Change
docstring, now it's called on the leading quote.
(python--treesit-fontify-string-end): New function.
(python--treesit-settings): Capture both leading and ending quote in a
string.
lisp/progmodes/python.el