comparison lisp/packages/info.el @ 70:131b0175ea99 r20-0b30

Import from CVS: tag r20-0b30
author cvs
date Mon, 13 Aug 2007 09:02:59 +0200
parents 56c54cf7c5b6
children 6a378aca36af
comparison
equal deleted inserted replaced
69:804d1389bcd6 70:131b0175ea99
359 "List of file name suffixes and associated decoding commands. 359 "List of file name suffixes and associated decoding commands.
360 Each entry should be (SUFFIX . STRING); if STRING contains %s, that is 360 Each entry should be (SUFFIX . STRING); if STRING contains %s, that is
361 changed to name of the file to decode, otherwise the file is given to 361 changed to name of the file to decode, otherwise the file is given to
362 the command as standard input. If STRING is nil, no decoding is done.") 362 the command as standard input. If STRING is nil, no decoding is done.")
363 363
364 (defvar Info-footnote-tag "Note" 364 (defvar Info-footnote-tag "See"
365 "*Symbol that identifies a footnote or cross-reference. 365 "*Symbol that identifies a footnote or cross-reference.
366 All \"*Note\" references will be changed to use this word instead.") 366 All \"*Note\" references will be changed to use this word instead.")
367 367
368 (defvar Info-current-file nil 368 (defvar Info-current-file nil
369 "Info file that Info is now looking at, or nil.") 369 "Info file that Info is now looking at, or nil.")
832 (run-hooks 'Info-select-hook) 832 (run-hooks 'Info-select-hook)
833 (if Info-enable-active-nodes (eval active-expression))))) 833 (if Info-enable-active-nodes (eval active-expression)))))
834 834
835 (defun Info-set-mode-line () 835 (defun Info-set-mode-line ()
836 (setq modeline-buffer-identification 836 (setq modeline-buffer-identification
837 (list (cons modeline-buffer-id-left-extent "Info: ") 837 (concat
838 (cons modeline-buffer-id-right-extent 838 "Info: ("
839 (concat 839 (if Info-current-file
840 "(" 840 (let ((name (file-name-nondirectory Info-current-file)))
841 (if Info-current-file 841 (if (string-match "\\.info$" name)
842 (let ((name (file-name-nondirectory Info-current-file))) 842 (substring name 0 -5)
843 (if (string-match "\\.info$" name) 843 name))
844 (substring name 0 -5) 844 "")
845 name)) 845 ")"
846 "") 846 (or Info-current-node ""))))
847 ")" 847
848 (or Info-current-node ""))))))
849
850 ;; Go to an info node specified with a filename-and-nodename string 848 ;; Go to an info node specified with a filename-and-nodename string
851 ;; of the sort that is found in pointers in nodes. 849 ;; of the sort that is found in pointers in nodes.
852 850
853 ;;;###autoload 851 ;;;###autoload
854 (defun Info-goto-node (nodename &optional no-going-back tryfile) 852 (defun Info-goto-node (nodename &optional no-going-back tryfile)
1824 (defun Info-exit () 1822 (defun Info-exit ()
1825 "Exit Info by selecting some other buffer." 1823 "Exit Info by selecting some other buffer."
1826 (interactive) 1824 (interactive)
1827 (if Info-standalone 1825 (if Info-standalone
1828 (save-buffers-kill-emacs) 1826 (save-buffers-kill-emacs)
1829 (bury-buffer (current-buffer)) 1827 (switch-to-buffer (prog1 (other-buffer (current-buffer))
1830 (if (and (featurep 'toolbar) 1828 (bury-buffer (current-buffer))
1831 (eq toolbar-info-frame (selected-frame))) 1829 (if (featurep 'toolbar)
1832 (condition-case nil 1830 (if (frame-live-p toolbar-info-frame)
1833 (delete-frame toolbar-info-frame) 1831 (delete-frame toolbar-info-frame)))))))
1834 (error (bury-buffer)))
1835 (switch-to-buffer (other-buffer (current-buffer))))))
1836 1832
1837 (defun Info-undefined () 1833 (defun Info-undefined ()
1838 "Make command be undefined in Info." 1834 "Make command be undefined in Info."
1839 (interactive) 1835 (interactive)
1840 (ding)) 1836 (ding))