(url): Define end-op property again. Wrap end-op
and beginning-op lambdas with `function', not quote.
This commit is contained in:
parent
cf09633a19
commit
a1c9b4d080
1 changed files with 11 additions and 9 deletions
|
|
@ -299,16 +299,18 @@ point."
|
|||
(goto-char match)
|
||||
(looking-at regexp)))))
|
||||
|
||||
;; Can't do it sensibly?
|
||||
;(put 'url 'end-op
|
||||
; '(lambda () (skip-chars-forward (concat ":" thing-at-point-url-chars))
|
||||
; (skip-chars-backward ".,:")))
|
||||
(put 'url 'end-op
|
||||
(function (lambda ()
|
||||
(let ((bounds (thing-at-point-bounds-of-url-at-point)))
|
||||
(if bounds
|
||||
(goto-char (cdr bounds))
|
||||
(error "No URL here"))))))
|
||||
(put 'url 'beginning-op
|
||||
'(lambda ()
|
||||
(let ((bounds (thing-at-point-bounds-of-url-at-point)))
|
||||
(if bounds
|
||||
(goto-char (car bounds))
|
||||
(error "No URL here")))))
|
||||
(function (lambda ()
|
||||
(let ((bounds (thing-at-point-bounds-of-url-at-point)))
|
||||
(if bounds
|
||||
(goto-char (car bounds))
|
||||
(error "No URL here"))))))
|
||||
|
||||
;; Whitespace
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue