diff options
| -rw-r--r-- | lisp/ChangeLog | 11 | ||||
| -rw-r--r-- | lisp/dired.el | 45 |
2 files changed, 15 insertions, 41 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 8c84b370b49..d30176d1992 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,14 @@ | |||
| 1 | 2005-01-01 Richard M. Stallman <rms@gnu.org> | ||
| 2 | |||
| 3 | * cus-face.el (custom-face-attributes): Fix :help-echo strings | ||
| 4 | for :foreground and :background. | ||
| 5 | |||
| 6 | 2004-12-31 Richard M. Stallman <rms@gnu.org> | ||
| 7 | |||
| 8 | * dired.el (dired-view-command-alist): Variable deleted. | ||
| 9 | (dired-view-file, dired-mouse-find-file-other-window): | ||
| 10 | Delete the code to use it. | ||
| 11 | |||
| 1 | 2005-01-01 Kim F. Storm <storm@cua.dk> | 12 | 2005-01-01 Kim F. Storm <storm@cua.dk> |
| 2 | 13 | ||
| 3 | * image.el (insert-sliced-image): Use t for line-height property. | 14 | * image.el (insert-sliced-image): Use t for line-height property. |
diff --git a/lisp/dired.el b/lisp/dired.el index 037bf282eda..0341214a98e 100644 --- a/lisp/dired.el +++ b/lisp/dired.el | |||
| @@ -200,22 +200,6 @@ with the buffer narrowed to the listing." | |||
| 200 | ;; Note this can't simply be run inside function `dired-ls' as the hook | 200 | ;; Note this can't simply be run inside function `dired-ls' as the hook |
| 201 | ;; functions probably depend on the dired-subdir-alist to be OK. | 201 | ;; functions probably depend on the dired-subdir-alist to be OK. |
| 202 | 202 | ||
| 203 | ;; Fixme: This should use mailcap. | ||
| 204 | (defcustom dired-view-command-alist | ||
| 205 | '(("\\.\\(ps\\|ps_pages\\|eps\\)\\'" . "gv %s") | ||
| 206 | ("\\.pdf\\'" . "xpdf %s") | ||
| 207 | ;; ("\\.pod\\'" . "perldoc %s") | ||
| 208 | ("\\.\\(jpe?g\\|gif\\|png\\)\\'" . "eog %s") | ||
| 209 | ("\\.dvi\\'" . "xdvi %s")) | ||
| 210 | "Alist specifying how to view special types of files. | ||
| 211 | Each element has the form (REGEXP . SHELL-COMMAND). | ||
| 212 | When the file name matches REGEXP, `dired-view-file' | ||
| 213 | invokes SHELL-COMMAND to view the file, processing it through `format'. | ||
| 214 | Use `%s' in SHELL-COMMAND to specify where to put the file name." | ||
| 215 | :group 'dired | ||
| 216 | :type '(alist :key-type regexp :value-type string) | ||
| 217 | :version "21.4") | ||
| 218 | |||
| 219 | ;; Internal variables | 203 | ;; Internal variables |
| 220 | 204 | ||
| 221 | (defvar dired-marker-char ?* ; the answer is 42 | 205 | (defvar dired-marker-char ?* ; the answer is 42 |
| @@ -1666,41 +1650,20 @@ Creates a buffer if necessary." | |||
| 1666 | (progn | 1650 | (progn |
| 1667 | (select-window window) | 1651 | (select-window window) |
| 1668 | (dired-other-window file))) | 1652 | (dired-other-window file))) |
| 1669 | (let (cmd) | 1653 | (select-window window) |
| 1670 | ;; Look for some other way to view a certain file. | 1654 | (find-file-other-window (file-name-sans-versions file t))))) |
| 1671 | (dolist (elt dired-view-command-alist) | ||
| 1672 | (if (string-match (car elt) file) | ||
| 1673 | (setq cmd (cdr elt)))) | ||
| 1674 | (if cmd | ||
| 1675 | (call-process shell-file-name nil 0 nil | ||
| 1676 | "-c" | ||
| 1677 | (concat (format cmd (shell-quote-argument file)) | ||
| 1678 | " &")) | ||
| 1679 | (select-window window) | ||
| 1680 | (find-file-other-window (file-name-sans-versions file t))))))) | ||
| 1681 | 1655 | ||
| 1682 | (defun dired-view-file () | 1656 | (defun dired-view-file () |
| 1683 | "In Dired, examine a file in view mode, returning to dired when done. | 1657 | "In Dired, examine a file in view mode, returning to dired when done. |
| 1684 | When file is a directory, show it in this buffer if it is inserted. | 1658 | When file is a directory, show it in this buffer if it is inserted. |
| 1685 | Some kinds of files are displayed using external viewer programs; | 1659 | Otherwise, display it in another buffer." |
| 1686 | see `dired-view-command-alist'. Otherwise, display it in another buffer." | ||
| 1687 | (interactive) | 1660 | (interactive) |
| 1688 | (let ((file (dired-get-file-for-visit))) | 1661 | (let ((file (dired-get-file-for-visit))) |
| 1689 | (if (file-directory-p file) | 1662 | (if (file-directory-p file) |
| 1690 | (or (and (cdr dired-subdir-alist) | 1663 | (or (and (cdr dired-subdir-alist) |
| 1691 | (dired-goto-subdir file)) | 1664 | (dired-goto-subdir file)) |
| 1692 | (dired file)) | 1665 | (dired file)) |
| 1693 | (let (cmd) | 1666 | (view-file file)))) |
| 1694 | ;; Look for some other way to view a certain file. | ||
| 1695 | (dolist (elt dired-view-command-alist) | ||
| 1696 | (if (string-match (car elt) file) | ||
| 1697 | (setq cmd (cdr elt)))) | ||
| 1698 | (if cmd | ||
| 1699 | (call-process shell-file-name nil 0 nil | ||
| 1700 | "-c" | ||
| 1701 | (concat (format cmd (shell-quote-argument file)) | ||
| 1702 | " &")) | ||
| 1703 | (view-file file)))))) | ||
| 1704 | 1667 | ||
| 1705 | (defun dired-find-file-other-window () | 1668 | (defun dired-find-file-other-window () |
| 1706 | "In Dired, visit this file or directory in another window." | 1669 | "In Dired, visit this file or directory in another window." |