branch: externals/indent-bars
commit d883507335a4e8ce537ba2a95190261ccd488bb0
Author: JD Smith <[email protected]>
Commit: JD Smith <[email protected]>

    docs: improve update-scope1 docstring
---
 indent-bars-ts.el | 13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)

diff --git a/indent-bars-ts.el b/indent-bars-ts.el
index 4f94462e16..59be1ceb5e 100644
--- a/indent-bars-ts.el
+++ b/indent-bars-ts.el
@@ -301,13 +301,14 @@ both) of them cover."
     l))
 
 (defun indent-bars-ts--update-scope1 ()
-  "Perform the treesitter scope update.
+  "Perform the treesitter scope font-lock update.
 If the buffer is modified or the point has moved, re-query the
-scope bounds.  If it has changed (beyond normal marker movement),
-refontify the symmetric difference between the old and new
-ranges (i.e those ranges covered by either old or new, but not
-both)."
-  (unless (or (not ibtcs) ; can be called in other buffers too
+scope bounds at point.  If the current scope range, clipped to
+the window's bounds, falls outside the prior scope (beyond normal
+marker movement), refontify the union of old and new clipped
+ranges and update.  Note that the updated node range clips to an
+\"extended window\" with 50% padding on either side."
+  (unless (or (not ibtcs) ; can be called from other buffers!
              (and (= (point) (ibts/point ibtcs))
                   (= (buffer-modified-tick) (ibts/tick ibtcs))))
     (when-let ((node (treesit-node-on

Reply via email to