How can I manage with Emacs dired-mode colors?

For example, if I want to make column with file's last modified time and date to be red-colored.


As is typical in Emacs, you set font-lock-keywords in the particular mode, in this case dired-mode.

Library Dired+ does this extensively for Dired mode. You can customize the faces that it provides, if you just want to change a color etc. from the default value.

If it does not already color things the way you want, then look at the dired+.el code for setting font-lock-keywords, for inspiration.

  • Should I use Dired+ instead of Dired for colorfill some columns? – drobnbobn Mar 8 '16 at 2:28
  • You can, yes. It's easy enough to try (a single file). If it doesn't color exactly what you want you can at least look at how it does color things and do similarly to get what you want. – Drew Mar 8 '16 at 3:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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