(goto-address-url-face): Change default value from `bold' to `link'.
[bpt/emacs.git] / lisp / dired-aux.el
index 358e852..3bc5f4b 100644 (file)
@@ -1,7 +1,7 @@
 ;;; dired-aux.el --- less commonly used parts of dired  -*-byte-compile-dynamic: t;-*-
 
 ;; Copyright (C) 1985, 1986, 1992, 1994, 1998, 2000, 2001, 2002, 2003,
-;;   2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
+;;   2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
 
 ;; Author: Sebastian Kremer <sk@thp.uni-koeln.de>.
 ;; Maintainer: FSF
@@ -1166,7 +1166,7 @@ See Info node `(emacs)Subdir switches' for more details."
 ;;; Copy, move/rename, making hard and symbolic links
 
 (defcustom dired-backup-overwrite nil
-  "*Non-nil if Dired should ask about making backups before overwriting files.
+  "Non-nil if Dired should ask about making backups before overwriting files.
 Special value `always' suppresses confirmation."
   :type '(choice (const :tag "off" nil)
                 (const :tag "suppress" always)
@@ -2304,7 +2304,7 @@ Use \\[dired-hide-subdir] to (un)hide a particular subdirectory."
 ;; Search only in file names in the Dired buffer.
 
 (defcustom dired-isearch-filenames nil
-  "*Non-nil to Isearch in file names only.
+  "Non-nil to Isearch in file names only.
 If t, Isearch in Dired always matches only file names.
 If `dwim', Isearch matches file names when initial point position is on
 a file name.  Otherwise, it searches the whole buffer without restrictions."
@@ -2320,11 +2320,11 @@ a file name.  Otherwise, it searches the whole buffer without restrictions."
   "Toggle file names searching on or off.
 When on, Isearch skips matches outside file names using the predicate
 `dired-isearch-filter-filenames' that matches only at file names.
-When off, it uses the default predicate `isearch-filter-invisible'."
+When off, it uses the original predicate."
   (interactive)
   (setq isearch-filter-predicate
        (if (eq isearch-filter-predicate 'dired-isearch-filter-filenames)
-           'isearch-filter-invisible
+           dired-isearch-filter-predicate-orig
          'dired-isearch-filter-filenames))
   (setq isearch-success t isearch-adjusted t)
   (isearch-update))
@@ -2351,8 +2351,10 @@ Intended to be added to `isearch-mode-hook'."
   (remove-hook 'isearch-mode-end-hook 'dired-isearch-filenames-end t))
 
 (defun dired-isearch-filter-filenames (beg end)
-  "Match only at visible regions with the text property `dired-filename'."
-  (and (isearch-filter-invisible beg end)
+  "Test whether the current search hit is a visible file name.
+Return non-nil if the text from BEG to END is part of a file
+name (has the text property `dired-filename') and is visible."
+  (and (isearch-filter-visible beg end)
        (if dired-isearch-filenames
           (text-property-not-all (min beg end) (max beg end)
                                  'dired-filename nil)