[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/lisp/emulation/tpu-edt.el
From: |
Richard M . Stallman |
Subject: |
[Emacs-diffs] Changes to emacs/lisp/emulation/tpu-edt.el |
Date: |
Sun, 03 Jul 2005 15:25:20 -0400 |
Index: emacs/lisp/emulation/tpu-edt.el
diff -c emacs/lisp/emulation/tpu-edt.el:1.39
emacs/lisp/emulation/tpu-edt.el:1.40
*** emacs/lisp/emulation/tpu-edt.el:1.39 Sun Jul 3 19:20:21 2005
--- emacs/lisp/emulation/tpu-edt.el Sun Jul 3 19:25:20 2005
***************
*** 307,324 ****
;;; Emacs version identifiers - currently referenced by
;;;
;;; o tpu-mark o tpu-set-mark
! ;;; o tpu-string-prompt o tpu-regexp-prompt
! ;;; o tpu-edt-on o tpu-load-xkeys
! ;;; o tpu-update-mode-line o mode line section
;;;
- (defconst tpu-emacs19-p (not (string-lessp emacs-version "19"))
- "Non-nil if we are running Lucid Emacs or version 19.")
-
(defconst tpu-lucid-emacs19-p
! (and tpu-emacs19-p (string-match "Lucid" emacs-version))
"Non-nil if we are running Lucid Emacs version 19.")
-
;;;
;;; Global Keymaps
;;;
--- 307,318 ----
;;; Emacs version identifiers - currently referenced by
;;;
;;; o tpu-mark o tpu-set-mark
! ;;; o mode line section o tpu-load-xkeys
;;;
(defconst tpu-lucid-emacs19-p
! (string-match "Lucid" emacs-version)
"Non-nil if we are running Lucid Emacs version 19.")
;;;
;;; Global Keymaps
;;;
***************
*** 463,475 ****
(defun tpu-update-mode-line nil
"Make sure mode-line in the current buffer reflects all changes."
(setq tpu-mark-flag (if transient-mark-mode "" (if (tpu-mark) " @" " ")))
! (cond (tpu-emacs19-p (force-mode-line-update))
! (t (set-buffer-modified-p (buffer-modified-p)) (sit-for 0))))
(cond (tpu-lucid-emacs19-p
(add-hook 'zmacs-deactivate-region-hook 'tpu-update-mode-line)
(add-hook 'zmacs-activate-region-hook 'tpu-update-mode-line))
! (tpu-emacs19-p
(add-hook 'activate-mark-hook 'tpu-update-mode-line)
(add-hook 'deactivate-mark-hook 'tpu-update-mode-line)))
--- 457,468 ----
(defun tpu-update-mode-line nil
"Make sure mode-line in the current buffer reflects all changes."
(setq tpu-mark-flag (if transient-mark-mode "" (if (tpu-mark) " @" " ")))
! (force-mode-line-update))
(cond (tpu-lucid-emacs19-p
(add-hook 'zmacs-deactivate-region-hook 'tpu-update-mode-line)
(add-hook 'zmacs-activate-region-hook 'tpu-update-mode-line))
! (t
(add-hook 'activate-mark-hook 'tpu-update-mode-line)
(add-hook 'deactivate-mark-hook 'tpu-update-mode-line)))
***************
*** 542,554 ****
(defun tpu-caar (thingy) (car (car thingy)))
(defun tpu-cadr (thingy) (car (cdr thingy)))
(defun tpu-mark nil
"TPU-edt version of the mark function.
Return the appropriate value of the mark for the current
version of Emacs."
(cond (tpu-lucid-emacs19-p (mark (not zmacs-regions)))
! (tpu-emacs19-p (and mark-active (mark (not transient-mark-mode))))
! (t (mark))))
(defun tpu-set-mark (pos)
"TPU-edt version of the `set-mark' function.
--- 535,548 ----
(defun tpu-caar (thingy) (car (car thingy)))
(defun tpu-cadr (thingy) (car (cdr thingy)))
+ (defvar zmacs-regions)
+
(defun tpu-mark nil
"TPU-edt version of the mark function.
Return the appropriate value of the mark for the current
version of Emacs."
(cond (tpu-lucid-emacs19-p (mark (not zmacs-regions)))
! (and mark-active (mark (not transient-mark-mode)))))
(defun tpu-set-mark (pos)
"TPU-edt version of the `set-mark' function.
***************
*** 559,567 ****
(defun tpu-string-prompt (prompt history-symbol)
"Read a string with PROMPT."
! (if tpu-emacs19-p
! (read-from-minibuffer prompt nil nil nil history-symbol)
! (read-string prompt)))
(defvar tpu-last-answer nil "Most recent response to tpu-y-or-n-p.")
--- 553,559 ----
(defun tpu-string-prompt (prompt history-symbol)
"Read a string with PROMPT."
! (read-from-minibuffer prompt nil nil nil history-symbol))
(defvar tpu-last-answer nil "Most recent response to tpu-y-or-n-p.")
***************
*** 1118,1126 ****
(defun tpu-regexp-prompt (prompt)
"Read a string, adding 'RE' to the prompt if tpu-regexp-p is set."
(let ((re-prompt (concat (if tpu-regexp-p "RE ") prompt)))
! (if tpu-emacs19-p
! (read-from-minibuffer re-prompt nil nil nil 'tpu-regexp-prompt-hist)
! (read-string re-prompt))))
(defun tpu-search-highlight nil
(if (tpu-check-match)
--- 1110,1116 ----
(defun tpu-regexp-prompt (prompt)
"Read a string, adding 'RE' to the prompt if tpu-regexp-p is set."
(let ((re-prompt (concat (if tpu-regexp-p "RE ") prompt)))
! (read-from-minibuffer re-prompt nil nil nil 'tpu-regexp-prompt-hist)))
(defun tpu-search-highlight nil
(if (tpu-check-match)
***************
*** 2408,2414 ****
(tpu-lucid-emacs19-p
(setq file (convert-standard-filename
(expand-file-name "~/.tpu-lucid-keys"))))
! (tpu-emacs19-p
(setq file (convert-standard-filename
(expand-file-name "~/.tpu-keys")))
(and (not (file-exists-p file))
--- 2398,2404 ----
(tpu-lucid-emacs19-p
(setq file (convert-standard-filename
(expand-file-name "~/.tpu-lucid-keys"))))
! (t
(setq file (convert-standard-filename
(expand-file-name "~/.tpu-keys")))
(and (not (file-exists-p file))