[slime-cvs] CVS update: slime/slime.el

Luke Gorrie lgorrie at common-lisp.net
Fri Jan 14 17:08:37 UTC 2005


Update of /project/slime/cvsroot/slime
In directory common-lisp.net:/tmp/cvs-serv21813

Modified Files:
	slime.el 
Log Message:
(slime-repl-send-input): Make old input read-only using an overlay
instead of a text property. This way if you copy&paste the input
elsewhere it will become editable (overlay is associated with the
buffer region and not the text).

Date: Fri Jan 14 18:08:34 2005
Author: lgorrie

Index: slime/slime.el
diff -u slime/slime.el:1.447 slime/slime.el:1.448
--- slime/slime.el:1.447	Fri Jan 14 08:59:20 2005
+++ slime/slime.el	Fri Jan 14 18:08:33 2005
@@ -2751,16 +2751,13 @@
                               rear-nonsticky (face slime-repl-old-input)
                               slime-repl-old-input 
                               ,(incf slime-repl-old-input-counter)))
-  (slime-make-region-read-only  slime-repl-input-start-mark (point))
+  (let ((overlay (make-overlay slime-repl-input-start-mark (point))))
+    (overlay-put overlay 'read-only t))
   (let ((input (slime-repl-current-input)))
     (goto-char slime-repl-input-end-mark)
     (slime-mark-input-start)
     (slime-mark-output-start)
     (slime-repl-send-string input)))
-
-(defun slime-make-region-read-only (start end)
-  (add-text-properties (max start (1- end)) end '(rear-nonsticky (read-only)))
-  (add-text-properties start end `(read-only t)))
 
 (defun slime-repl-grab-old-input (replace)
   "Resend the old REPL input at point.  




More information about the slime-cvs mailing list