aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJim Blandy1991-02-20 08:29:50 +0000
committerJim Blandy1991-02-20 08:29:50 +0000
commitfe79ff619909a3e7ffd82e32ede5670bad458fec (patch)
treeae1fcc069f8f7841a04ba60563f5d96a6e0522e7
parent353ea2e65954ff6eb143926a7191ae351bb69116 (diff)
downloademacs-fe79ff619909a3e7ffd82e32ede5670bad458fec.tar.gz
emacs-fe79ff619909a3e7ffd82e32ede5670bad458fec.zip
*** empty log message ***
-rw-r--r--lisp/mouse.el21
1 files changed, 20 insertions, 1 deletions
diff --git a/lisp/mouse.el b/lisp/mouse.el
index 924bc71d837..9c9bc4921b6 100644
--- a/lisp/mouse.el
+++ b/lisp/mouse.el
@@ -82,9 +82,28 @@ Display cursor at that position for a second."
82 (unwind-protect 82 (unwind-protect
83 (progn (mouse-set-point event) 83 (progn (mouse-set-point event)
84 (push-mark nil t) 84 (push-mark nil t)
85 (sleep-for 1)) 85 (sit-for 1))
86 (goto-char point-save)))) 86 (goto-char point-save))))
87 87
88(defun mouse-fill-paragraph (event)
89 "Fill the paragraph at the mouse position."
90 (interactive "@e")
91 (save-excursion
92 (mouse-set-point event)
93 (fill-paragraph)))
94
95(defun mouse-fill-paragraph-with-prefix (event)
96 "Fill the paragraph at the mouse position with specified fill prefix.
97Click at the end of the fill prefix that you want;
98The text before the mouse position, on the same line, is used as the prefix."
99 (interactive "@e")
100 (save-excursion
101 (mouse-set-point event)
102 (let ((fill-prefix (buffer-substring (save-excursion (beginning-of-line)
103 (point))
104 (point))))
105 (fill-paragraph))))
106
88(defun mouse-scroll (event) 107(defun mouse-scroll (event)
89 "Scroll point to the mouse position." 108 "Scroll point to the mouse position."
90 (interactive "@e") 109 (interactive "@e")