1
0
mirror of https://github.com/m00natic/vlfi.git synced 2024-10-05 18:30:51 +01:00

Fix cursor position after search

After searching forward (resp. backward) the cursor should be at the
end (resp. the beginning) of the match. That way one can jump to the
next match by running again the command.
This commit is contained in:
Nil Geisweiller 2017-03-30 16:39:12 +03:00 committed by Andrey Kotlarski
parent a8ba8363b2
commit eaa3629227

View File

@ -140,10 +140,10 @@ Return t if search has been at least partially successful."
(let ((result
(if backward
(vlf-goto-match match-chunk-start match-chunk-end
match-end-pos match-start-pos
match-start-pos match-end-pos
count to-find time highlight)
(vlf-goto-match match-chunk-start match-chunk-end
match-start-pos match-end-pos
match-end-pos match-start-pos
count to-find time highlight))))
(run-hook-with-args 'vlf-after-batch-functions 'search)
result)))))