Mercurial > emacs
comparison lisp/emulation/cua-gmrk.el @ 63870:66f83ad1a264
(cua-toggle-global-mark, cua-cut-region-to-global-mark,
cua--cut-rectangle-to-global-mark): Remove period from end of error messages.
author | Juanma Barranquero <lekktu@gmail.com> |
---|---|
date | Thu, 30 Jun 2005 01:13:21 +0000 |
parents | f1bf3660220e |
children | 18a818a2ee7c |
comparison
equal
deleted
inserted
replaced
63869:e7c533a3b1b9 | 63870:66f83ad1a264 |
---|---|
94 "Set or cancel the global marker. | 94 "Set or cancel the global marker. |
95 When the global marker is set, CUA cut and copy commands will automatically | 95 When the global marker is set, CUA cut and copy commands will automatically |
96 insert the deleted or copied text before the global marker, even when the | 96 insert the deleted or copied text before the global marker, even when the |
97 global marker is in another buffer. | 97 global marker is in another buffer. |
98 If the global marker isn't set, set the global marker at point in the current | 98 If the global marker isn't set, set the global marker at point in the current |
99 buffer. Otherwise jump to the global marker position and cancel it. | 99 buffer. Otherwise jump to the global marker position and cancel it. |
100 With prefix argument, don't jump to global mark when cancelling it." | 100 With prefix argument, don't jump to global mark when cancelling it." |
101 (interactive "P") | 101 (interactive "P") |
102 (unless cua--global-mark-initialized | 102 (unless cua--global-mark-initialized |
103 (cua--init-global-mark)) | 103 (cua--init-global-mark)) |
104 (if (not (cua--global-mark-active)) | 104 (if (not (cua--global-mark-active)) |
105 (if (not buffer-read-only) | 105 (if (not buffer-read-only) |
106 (cua--activate-global-mark t) | 106 (cua--activate-global-mark t) |
107 (ding) | 107 (ding) |
108 (message "Cannot set global mark in read-only buffer.")) | 108 (message "Cannot set global mark in read-only buffer")) |
109 (when (not stay) | 109 (when (not stay) |
110 (pop-to-buffer (marker-buffer cua--global-mark-marker)) | 110 (pop-to-buffer (marker-buffer cua--global-mark-marker)) |
111 (goto-char cua--global-mark-marker)) | 111 (goto-char cua--global-mark-marker)) |
112 (cua--deactivate-global-mark t))) | 112 (cua--deactivate-global-mark t))) |
113 | 113 |
163 (let ((src-buf (current-buffer))) | 163 (let ((src-buf (current-buffer))) |
164 (save-excursion | 164 (save-excursion |
165 (if (equal (marker-buffer cua--global-mark-marker) src-buf) | 165 (if (equal (marker-buffer cua--global-mark-marker) src-buf) |
166 (if (and (< start (marker-position cua--global-mark-marker)) | 166 (if (and (< start (marker-position cua--global-mark-marker)) |
167 (< (marker-position cua--global-mark-marker) end)) | 167 (< (marker-position cua--global-mark-marker) end)) |
168 (message "Can't move region into itself.") | 168 (message "Can't move region into itself") |
169 (let ((text (buffer-substring-no-properties start end)) | 169 (let ((text (buffer-substring-no-properties start end)) |
170 (p1 (copy-marker start)) | 170 (p1 (copy-marker start)) |
171 (p2 (copy-marker end))) | 171 (p2 (copy-marker end))) |
172 (goto-char (marker-position cua--global-mark-marker)) | 172 (goto-char (marker-position cua--global-mark-marker)) |
173 (insert text) | 173 (insert text) |
220 (while olist | 220 (while olist |
221 (if (eq (overlay-get (car olist) 'face) 'cua-rectangle) | 221 (if (eq (overlay-get (car olist) 'face) 'cua-rectangle) |
222 (setq in-rect t olist nil) | 222 (setq in-rect t olist nil) |
223 (setq olist (cdr olist)))) | 223 (setq olist (cdr olist)))) |
224 (if in-rect | 224 (if in-rect |
225 (message "Can't move rectangle into itself.") | 225 (message "Can't move rectangle into itself") |
226 (let ((text (cua--extract-rectangle))) | 226 (let ((text (cua--extract-rectangle))) |
227 (cua--delete-rectangle) | 227 (cua--delete-rectangle) |
228 (goto-char (marker-position cua--global-mark-marker)) | 228 (goto-char (marker-position cua--global-mark-marker)) |
229 (if as-text | 229 (if as-text |
230 (while text | 230 (while text |