Emacs 27.1
package Dired+, Version: 2023.01.14
Here screen
As you can see the foreground of suffix compress file is correct (orange). Nice.
But the foreground of name compress file is not change (must be blue).
Why?
Emacs 27.1
package Dired+, Version: 2023.01.14
Here screen
As you can see the foreground of suffix compress file is correct (orange). Nice.
But the foreground of name compress file is not change (must be blue).
Why?
Put your cursor on a colored character and use C-x =
. Near the bottom of buffer *Help*
you'll see the faces used for that character.
Use M-x customize-face
to customize any face. Save your changes (in Customize).
On the suffix for a compressed file, C-x =
tells me this:
There are text properties here:
dired-filename t
face diredp-compressed-file-suffix
fontified t
help-echo diredp-mouseover-help
mouse-face highlight
On the base file name (not the suffix), C-x =
tells me this:
There are text properties here:
dired-filename t
face diredp-compressed-file-name
fontified t
help-echo diredp-mouseover-help
mouse-face highlight
M-x customize-face RET diredp-compressed-file-name RET
will tell you how that face is currently defined, and let you change its appearance.
However, option diredp-ignore-compressed-flag
controls this also, and by default it is non-nil
:
diredp-ignore-compressed-flag
is a variable defined indired+.el
.Its value is
t
Documentation:
Non-
nil
means to font-lock names of compressed files as ignored files.This applies to filenames whose extensions are in
diredp-compressed-extensions
. Ifnil
they are highlighted using facediredp-compressed-file-name
.Note: If you change the value of this option then you need to restart Emacs to see the effect of the new value on font-locking.
You can customize this variable.
So if diredp-ignore-compressed-flag
is non-nil
then the face you might want to customize is diredp-ignored-file-name
. (And in that case, *Help*
will have told you that that's the face used on the base file name.)
The Dired+ doc (see the Commentary in file dired+.el
, for instance) tells you:
You can use key
C-down
orC-up
to navigate to the next or previous file line, respectively, and at the same time show its file in another window. The focus remains on the Dired buffer. A numeric prefix arg means move that many lines first.Names of files and directories that match either of the options
diredp-visit-ignore-extensions
ordiredp-visit-ignore-regexps
are skipped.
This is one reason that compressed files are "ignored", by default: when cycling among files in a listing using, say, C-down
, you generally might not want to open compressed files. If this is the case then you will want to add their extensions (e.g. Z
, tgz
, etc.) to the value of option diredp-visit-ignore-extensions
.
UPDATE after your comment:
You added a comment that says that your diredp-ignore-compressed-flag
is nil
, but (I guess?) you're still seeing its non-nil
effect.
Your saying only this tells us nothing helpful:
"C-x =" - Char: m (109, #o155, #x6d) point=947 of 1210 (78%) column=49
You need to look at the bottom of the *Help*
buffer, to see what face is being used there. See what I wrote and show, above.
I'm guessing you didn't save the nil
value after changing option diredp-ignore-compressed-flag
to nil
with M-x customize-option
. Or if you did, you didn't start a new Emacs session to see the effect.
Did you read this part of the dired+.el
Commentary?
;; A few of the user options defined here have an effect on
;; font-locking, and this effect is established only when Dired+ is
;; loaded, which defines the font-lock keywords for Dired. These
;; options include `diredp-compressed-extensions',
;; `diredp-ignore-compressed-flag', `dired-omit-extensions', and
;; `diredp-omit-files-font-lock-regexp'. This means that if you
;; change the value of such an option then you will see the change
;; only in a new Emacs session.
In other words, you need to (1) change the option value to nil
, (2) save that change, and (3) start a new Emacs session to see the effect of the change.