4

This is superficially similar to a question I asked here but I think the answer might be different.

I'm trying to use dired+ and highlight but I don't seem to be getting the full functionality. When I do C-x d the resulting buffer is a regular dired buffer, without the dired+ formatting I've seen in various screenshots (where, for instance, autofile bookmarks are highlighted). C-h c C-x d tells me that the command being run is dired.

This 1.5-year-old discussion at Stack Overflow suggests adding the following keybinding to init.el:

(define-key ctl-x-map   "d" 'diredp-dired-files)
(define-key ctl-x-4-map "d" 'diredp-dired-files-other-window)

But this results in

Symbol's function definition is void

when I invoke C-x d after evaluation. Perhaps the name of these functions has changed since that answer was given, but looking at the completion possibilities when I try `M-x diredp-' I'm not sure where to turn.

6
  • 3
    Did you require dired+? (Ie (require 'dired+).) I forget that sometimes, and it would give you a similar error message. Nov 7, 2014 at 18:48
  • Yes, I've got that (though I have also forgotten it at times!). I also have (require 'dired-x) and (require 'highlight). Nov 7, 2014 at 18:57
  • 1
    Can you C-h f diredp-dired-files? If describe-function can't find it, it means you either don't have it loaded correctly or you have the wrong function name. If it can find it, it would suggest the problem is in your keybinding.
    – Dan
    Nov 7, 2014 at 19:31
  • 2
    Ah, turns out that, if you look in the source code, diredp-dired-files and diredp-dired-files-other-window were removed quite recently (9/14/2014).
    – Dan
    Nov 7, 2014 at 20:36
  • 1
    Following up: I don't used dired+, but in glancing through the source code, I think the commands are now named diredp-dired-for-files and diredp-dired-for-files-other-window.
    – Dan
    Nov 7, 2014 at 20:42

1 Answer 1

3
  1. Bookmark highlighting, including highlighting of autofile bookmarks, is provided by Bookmark+, not by Dired+.

  2. The old S.O. post you cite was up-to-date when it was written. Today, you just use command dired. It is advised, and functions it calls are modified, to do what the Dired+ doc says.

  3. You do not need to explicitly require dired-x.el - Dired+ does that.

  4. All the information you need should be in the dired+.el file header. If something is missing, please send me an email about it. Thx.

7
  • 1
    In my dired buffers, a .txt file looked just the same as a directory folder. After some fiddling, I realized that it was the fault of the zenburn theme I was using, which color-scheme canceled the work that dired+ was doing. Other themes represent things more correctly. Wow, that took me a long time to figure out. Thank you for your help. Onward and upward ... Nov 7, 2014 at 22:29
  • Hm. Just which faces does that theme trample on, which affect Dired(+)?
    – Drew
    Nov 7, 2014 at 22:30
  • Curiouser and curiouser. I went back to zenburn to answer your question more exactly, and suddenly everything is rainbows in here---it looks great. What just happened? I restarted emacs again, and am back to where I started. I'll look into this a little more today and see if I have anything cogent to say about it later on. Thanks for your help. Nov 7, 2014 at 22:37
  • Put your cursor on highlighted text and hit C-u C-x =, to see what face(s) are present at that position. That will tell you something about what is going on. Perhaps that theme alters some faces that are used by Dired(+), or that are inherited by faces that are used by Dired(+). You can also use M-x list-faces-display to see the currently available faces.
    – Drew
    Nov 7, 2014 at 22:42
  • I restarted emacs with the -Q switch, and enabled dired+, bookmark+ and highlight from there--everything works perfectly. So I think it must be a conflict with some other package I have loaded? Is 'trial and error' the only way to troubleshoot that kind of thing? If so, I'll get started. Nov 8, 2014 at 1:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.