comparison lisp/simple.el @ 921:c5c4c2ee8f26

*** empty log message ***
author Jim Blandy <jimb@redhat.com>
date Tue, 04 Aug 1992 02:36:45 +0000
parents 3a9943a4a440
children 9e51bb887797
comparison
equal deleted inserted replaced
920:7b984ce24013 921:c5c4c2ee8f26
390 (defvar minibuffer-history nil) 390 (defvar minibuffer-history nil)
391 (defvar minibuffer-history-sexp-flag nil) 391 (defvar minibuffer-history-sexp-flag nil)
392 (setq minibuffer-history-variable 'minibuffer-history) 392 (setq minibuffer-history-variable 'minibuffer-history)
393 (setq minibuffer-history-position nil) 393 (setq minibuffer-history-position nil)
394 394
395 (define-key minibuffer-local-map "\en" 'next-history-element) 395 (mapcar
396 (define-key minibuffer-local-ns-map "\en" 'next-history-element) 396 (function (lambda (key-and-command)
397 (define-key minibuffer-local-ns-map "\en" 'next-history-element) 397 (mapcar
398 (define-key minibuffer-local-completion-map "\en" 'next-history-element) 398 (function (lambda (keymap)
399 (define-key minibuffer-local-completion-map "\en" 'next-history-element) 399 (define-key (symbol-value keymap)
400 (define-key minibuffer-local-must-match-map "\en" 'next-history-element) 400 (car key-and-command)
401 401 (cdr key-and-command))))
402 (define-key minibuffer-local-map "\ep" 'previous-history-element) 402 '(minibuffer-local-map
403 (define-key minibuffer-local-ns-map "\ep" 'previous-history-element) 403 minibuffer-local-ns-map
404 (define-key minibuffer-local-ns-map "\ep" 'previous-history-element) 404 minibuffer-local-completion-map
405 (define-key minibuffer-local-completion-map "\ep" 'previous-history-element) 405 minibuffer-local-must-match-map))))
406 (define-key minibuffer-local-completion-map "\ep" 'previous-history-element) 406 '(("\en" . next-history-element) ([next] . next-history-element)
407 (define-key minibuffer-local-must-match-map "\ep" 'previous-history-element) 407 ("\ep" . previous-history-element) ([prior] . previous-history-element)
408 408 ("\er" . previous-matching-history-element)
409 (define-key minibuffer-local-map "\er" 'previous-matching-history-element) 409 ("\es" . next-matching-history-element)))
410 (define-key minibuffer-local-ns-map "\er" 'previous-matching-history-element)
411 (define-key minibuffer-local-ns-map "\er" 'previous-matching-history-element)
412 (define-key minibuffer-local-completion-map "\er"
413 'previous-matching-history-element)
414 (define-key minibuffer-local-completion-map "\er"
415 'previous-matching-history-element)
416 (define-key minibuffer-local-must-match-map "\er"
417 'previous-matching-history-element)
418
419 (define-key minibuffer-local-map "\es" 'next-matching-history-element)
420 (define-key minibuffer-local-ns-map "\es" 'next-matching-history-element)
421 (define-key minibuffer-local-ns-map "\es" 'next-matching-history-element)
422 (define-key minibuffer-local-completion-map "\es"
423 'next-matching-history-element)
424 (define-key minibuffer-local-completion-map "\es"
425 'next-matching-history-element)
426 (define-key minibuffer-local-must-match-map "\es"
427 'next-matching-history-element)
428 410
429 (put 'previous-matching-history-element 'enable-recursive-minibuffers t) 411 (put 'previous-matching-history-element 'enable-recursive-minibuffers t)
430 (defun previous-matching-history-element (regexp n) 412 (defun previous-matching-history-element (regexp n)
431 (interactive "sPrevious element matching (regexp): \np") 413 (interactive "sPrevious element matching (regexp): \np")
432 (let ((history (symbol-value minibuffer-history-variable)) 414 (let ((history (symbol-value minibuffer-history-variable))
870 If optional arg DO-NOT-MOVE is non-nil, then don't actually move the 852 If optional arg DO-NOT-MOVE is non-nil, then don't actually move the
871 yanking point; just return the Nth kill forward." 853 yanking point; just return the Nth kill forward."
872 (let ((interprogram-paste (and (= n 0) 854 (let ((interprogram-paste (and (= n 0)
873 interprogram-paste-function 855 interprogram-paste-function
874 (funcall interprogram-paste-function)))) 856 (funcall interprogram-paste-function))))
875 ;;; RMS: Turn off the interprogram paste feature
876 ;;; because currently it is wedged: it is always
877 ;;; giving a null string.
878 (setq interprogram-paste nil)
879 (if interprogram-paste 857 (if interprogram-paste
880 (progn 858 (progn
881 ;; Disable the interprogram cut function when we add the new 859 ;; Disable the interprogram cut function when we add the new
882 ;; text to the kill ring, so Emacs doesn't try to own the 860 ;; text to the kill ring, so Emacs doesn't try to own the
883 ;; selection, with identical text. 861 ;; selection, with identical text.