aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard M. Stallman1993-12-23 05:01:36 +0000
committerRichard M. Stallman1993-12-23 05:01:36 +0000
commitb9911289d39f9b0e03b8a53fb0476da402f43206 (patch)
tree39ba191bc4cbccbd9aaa9d84a28bba57594023a2
parentc20a77cc5940a7f835569ec475e97ee392d899a4 (diff)
downloademacs-b9911289d39f9b0e03b8a53fb0476da402f43206.tar.gz
emacs-b9911289d39f9b0e03b8a53fb0476da402f43206.zip
(picture-mode): Save the old truncate-lines value.
(picture-mode-exit): Restore that value.
-rw-r--r--lisp/textmodes/picture.el4
1 files changed, 4 insertions, 0 deletions
diff --git a/lisp/textmodes/picture.el b/lisp/textmodes/picture.el
index 3b6a5fe232c..d744d33f36c 100644
--- a/lisp/textmodes/picture.el
+++ b/lisp/textmodes/picture.el
@@ -509,6 +509,7 @@ Picture mode is invoked by the command \\[picture-mode].")
509(defvar picture-mode-old-local-map) 509(defvar picture-mode-old-local-map)
510(defvar picture-mode-old-mode-name) 510(defvar picture-mode-old-mode-name)
511(defvar picture-mode-old-major-mode) 511(defvar picture-mode-old-major-mode)
512(defvar picture-mode-old-truncate-lines)
512 513
513;;;###autoload 514;;;###autoload
514(defun picture-mode () 515(defun picture-mode ()
@@ -586,6 +587,8 @@ they are not defaultly assigned to keys."
586 (setq picture-tab-chars (default-value 'picture-tab-chars)) 587 (setq picture-tab-chars (default-value 'picture-tab-chars))
587 (make-local-variable 'picture-vertical-step) 588 (make-local-variable 'picture-vertical-step)
588 (make-local-variable 'picture-horizontal-step) 589 (make-local-variable 'picture-horizontal-step)
590 (make-local-variable 'picture-mode-old-truncate-lines)
591 (setq picture-mode-old-truncate-lines truncate-lines)
589 (setq truncate-lines t) 592 (setq truncate-lines t)
590 (picture-set-motion 0 1) 593 (picture-set-motion 0 1)
591 594
@@ -611,6 +614,7 @@ With no argument strips whitespace from end of every line in Picture buffer
611 (use-local-map picture-mode-old-local-map) 614 (use-local-map picture-mode-old-local-map)
612 (setq major-mode picture-mode-old-major-mode) 615 (setq major-mode picture-mode-old-major-mode)
613 (kill-local-variable 'tab-stop-list) 616 (kill-local-variable 'tab-stop-list)
617 (setq truncate-lines picture-mode-old-truncate-lines)
614 ;; Kludge - force the mode line to be updated. Is there a better 618 ;; Kludge - force the mode line to be updated. Is there a better
615 ;; way to do this? 619 ;; way to do this?
616 (set-buffer-modified-p (buffer-modified-p)))) 620 (set-buffer-modified-p (buffer-modified-p))))