mirror of
https://github.com/abo-abo/avy.git
synced 2025-10-13 05:23:05 +00:00
parent
9a15d1f37b
commit
85b5d574cd
7
avy.el
7
avy.el
@ -1223,19 +1223,20 @@ exist."
|
|||||||
(ignore #'ignore)
|
(ignore #'ignore)
|
||||||
(t (error "Unexpected style %S" style))))
|
(t (error "Unexpected style %S" style))))
|
||||||
|
|
||||||
(cl-defun avy-jump (regex &key window-flip beg end action)
|
(cl-defun avy-jump (regex &key window-flip beg end action pred)
|
||||||
"Jump to REGEX.
|
"Jump to REGEX.
|
||||||
The window scope is determined by `avy-all-windows'.
|
The window scope is determined by `avy-all-windows'.
|
||||||
When WINDOW-FLIP is non-nil, do the opposite of `avy-all-windows'.
|
When WINDOW-FLIP is non-nil, do the opposite of `avy-all-windows'.
|
||||||
BEG and END narrow the scope where candidates are searched.
|
BEG and END narrow the scope where candidates are searched.
|
||||||
ACTION is a function that takes point position as an argument."
|
ACTION is a function that takes point position as an argument.
|
||||||
|
When PRED is non-nil, it's a filter for matching point positions."
|
||||||
(setq avy-action (or action avy-action))
|
(setq avy-action (or action avy-action))
|
||||||
(let ((avy-all-windows
|
(let ((avy-all-windows
|
||||||
(if window-flip
|
(if window-flip
|
||||||
(not avy-all-windows)
|
(not avy-all-windows)
|
||||||
avy-all-windows)))
|
avy-all-windows)))
|
||||||
(avy-process
|
(avy-process
|
||||||
(avy--regex-candidates regex beg end))))
|
(avy--regex-candidates regex beg end pred))))
|
||||||
|
|
||||||
(defun avy--generic-jump (regex window-flip &optional beg end)
|
(defun avy--generic-jump (regex window-flip &optional beg end)
|
||||||
"Jump to REGEX.
|
"Jump to REGEX.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user