mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2024-11-28 07:45:00 +00:00
(dired-view-command-alist): Variable deleted.
(dired-view-file, dired-mouse-find-file-other-window): Delete the code to use it.
This commit is contained in:
parent
4bbe6176dc
commit
3f68d7c887
@ -1,3 +1,14 @@
|
||||
2005-01-01 Richard M. Stallman <rms@gnu.org>
|
||||
|
||||
* cus-face.el (custom-face-attributes): Fix :help-echo strings
|
||||
for :foreground and :background.
|
||||
|
||||
2004-12-31 Richard M. Stallman <rms@gnu.org>
|
||||
|
||||
* dired.el (dired-view-command-alist): Variable deleted.
|
||||
(dired-view-file, dired-mouse-find-file-other-window):
|
||||
Delete the code to use it.
|
||||
|
||||
2005-01-01 Kim F. Storm <storm@cua.dk>
|
||||
|
||||
* image.el (insert-sliced-image): Use t for line-height property.
|
||||
|
@ -200,22 +200,6 @@ with the buffer narrowed to the listing."
|
||||
;; Note this can't simply be run inside function `dired-ls' as the hook
|
||||
;; functions probably depend on the dired-subdir-alist to be OK.
|
||||
|
||||
;; Fixme: This should use mailcap.
|
||||
(defcustom dired-view-command-alist
|
||||
'(("\\.\\(ps\\|ps_pages\\|eps\\)\\'" . "gv %s")
|
||||
("\\.pdf\\'" . "xpdf %s")
|
||||
;; ("\\.pod\\'" . "perldoc %s")
|
||||
("\\.\\(jpe?g\\|gif\\|png\\)\\'" . "eog %s")
|
||||
("\\.dvi\\'" . "xdvi %s"))
|
||||
"Alist specifying how to view special types of files.
|
||||
Each element has the form (REGEXP . SHELL-COMMAND).
|
||||
When the file name matches REGEXP, `dired-view-file'
|
||||
invokes SHELL-COMMAND to view the file, processing it through `format'.
|
||||
Use `%s' in SHELL-COMMAND to specify where to put the file name."
|
||||
:group 'dired
|
||||
:type '(alist :key-type regexp :value-type string)
|
||||
:version "21.4")
|
||||
|
||||
;; Internal variables
|
||||
|
||||
(defvar dired-marker-char ?* ; the answer is 42
|
||||
@ -1666,41 +1650,20 @@ Creates a buffer if necessary."
|
||||
(progn
|
||||
(select-window window)
|
||||
(dired-other-window file)))
|
||||
(let (cmd)
|
||||
;; Look for some other way to view a certain file.
|
||||
(dolist (elt dired-view-command-alist)
|
||||
(if (string-match (car elt) file)
|
||||
(setq cmd (cdr elt))))
|
||||
(if cmd
|
||||
(call-process shell-file-name nil 0 nil
|
||||
"-c"
|
||||
(concat (format cmd (shell-quote-argument file))
|
||||
" &"))
|
||||
(select-window window)
|
||||
(find-file-other-window (file-name-sans-versions file t)))))))
|
||||
(select-window window)
|
||||
(find-file-other-window (file-name-sans-versions file t)))))
|
||||
|
||||
(defun dired-view-file ()
|
||||
"In Dired, examine a file in view mode, returning to dired when done.
|
||||
When file is a directory, show it in this buffer if it is inserted.
|
||||
Some kinds of files are displayed using external viewer programs;
|
||||
see `dired-view-command-alist'. Otherwise, display it in another buffer."
|
||||
Otherwise, display it in another buffer."
|
||||
(interactive)
|
||||
(let ((file (dired-get-file-for-visit)))
|
||||
(if (file-directory-p file)
|
||||
(or (and (cdr dired-subdir-alist)
|
||||
(dired-goto-subdir file))
|
||||
(dired file))
|
||||
(let (cmd)
|
||||
;; Look for some other way to view a certain file.
|
||||
(dolist (elt dired-view-command-alist)
|
||||
(if (string-match (car elt) file)
|
||||
(setq cmd (cdr elt))))
|
||||
(if cmd
|
||||
(call-process shell-file-name nil 0 nil
|
||||
"-c"
|
||||
(concat (format cmd (shell-quote-argument file))
|
||||
" &"))
|
||||
(view-file file))))))
|
||||
(view-file file))))
|
||||
|
||||
(defun dired-find-file-other-window ()
|
||||
"In Dired, visit this file or directory in another window."
|
||||
|
Loading…
Reference in New Issue
Block a user