]> git.eshelyaron.com Git - emacs.git/commitdiff
(dired-insert-directory): Preserve text properties when quoting.
authorAndreas Schwab <schwab@suse.de>
Sat, 21 Dec 2002 17:06:54 +0000 (17:06 +0000)
committerAndreas Schwab <schwab@suse.de>
Sat, 21 Dec 2002 17:06:54 +0000 (17:06 +0000)
lisp/ChangeLog
lisp/dired.el

index 167c1f73548de1d51527638aaba4a3f6e665e22f..3dbf8d5e0296184ea3085e411ab51397e68c3c86 100644 (file)
@@ -1,3 +1,8 @@
+2002-12-21  Andreas Schwab  <schwab@suse.de>
+
+       * dired.el (dired-insert-directory): Preserve text properties
+       when quoting.
+
 2002-12-20  Francesco Potort\e,Al\e(B  <pot@gnu.org>
 
        * mail/undigest.el (rmail-mail-separator): Renamed from
index 68c6ffc8bc1e25b38d47edd25d0899eb5315c093..11669400ad67772df57c047ffc97eee42f0a1418 100644 (file)
@@ -693,10 +693,16 @@ If HDR is non-nil, insert a header line with the directory name."
          (setq end (point-marker))
          (goto-char opoint)
          (while (search-forward "\\" end t)
-           (replace-match "\\\\" nil t))
+           (replace-match (apply #'propertize
+                                 "\\\\"
+                                 (text-properties-at (match-beginning 0)))
+                          nil t))
          (goto-char opoint)
          (while (search-forward "\^m" end t)
-           (replace-match "\\015" nil t))
+           (replace-match (apply #'propertize
+                                 "\\015"
+                                 (text-properties-at (match-beginning 0)))
+                          nil t))
          (set-marker end nil)))
     (dired-insert-set-properties opoint (point))
     ;; If we used --dired and it worked, the lines are already indented.