From: Juri Linkov <juri@jurta.org>
To: Eli Zaretskii <eliz@gnu.org>
Cc: emacs-devel@gnu.org
Subject: Re: 23.0.50; Middle w in of permissions in dired-mode is red and bold: dired-warning
Date: Thu, 13 Mar 2008 04:19:37 +0200 [thread overview]
Message-ID: <878x0n1g86.fsf@jurta.org> (raw)
In-Reply-To: <u8x65jq2q.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 15 Oct 2007 00:20:45 +0200")
>> Cc: emacs-devel@gnu.org
>> From: Juri Linkov <juri@jurta.org>
>> Date: Mon, 15 Oct 2007 00:21:01 +0300
>>
>> I don't understand the need of adding a new face `dired-warn-writable'?
>
> To get me off the hook with people who use dired-warning-face.
>
> I don't mind removing dired-warning-face, but its doc string is quite
> general:
>
> "Face used to highlight a part of a buffer that needs user attention."
>
> which to me means it could be used for something other than mode
> bits. "Perhaps someone customized dired-font-lock-keywords," says I,
> in which case leaving that face alone won't do any particular harm.
>
>> It adds another unnecessary face, and still doesn't fix a problem
>> of the annoying bold red indication of group and world writable permissions.
>
> It does fix that on platforms where group- and world-writable files
> are the default. On other platforms, you can customize it, or we can
> make it inherit from `default' on _all_ platforms. I didn't do it
> because I was unsure how many users of Unix and GNU systems actually
> want to pay attention to such files.
>
>> Otherwise, we could revert the `dired-warning' face to less annoying
>> colors
>
> As long as the face's name is *-warning, I think making it inherit
> from font-lock-warning-face is TRT: if we want to warn about
> something, let that something stand out like any other warning.
>
> That is why I renamed the face to something less general. And if the
> "warn" part isn't consistent enough with what I say above, it (the
> "warn" part of the face's name) can go away.
When testing Emacs 22 with `emacs -Q', I see that dired buffers are
almost unusable by default. The red bold face for write permissions
is very distracting that prevents focusing on other parts of the dired
buffer. I'm afraid Emacs users will hate us for this if we release
Emacs 22.2 with this annoyance.
I propose a patch below for the 22 branch that renames the face
`dired-warn-writable' to more appropriate name `dired-perm-write'
that doesn't associate it with a warning, and changes its parent face
from `font-lock-warning-face' to `font-lock-comment-delimiter-face'
on non-Windows platforms.
The face `dired-warning' that inherits from `font-lock-warning-face'
still remains in dired.el, but it is not used anywhere.
Index: lisp/dired.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/dired.el,v
retrieving revision 1.359.2.10
diff -c -r1.359.2.10 dired.el
*** lisp/dired.el 22 Feb 2008 18:47:26 -0000 1.359.2.10
--- lisp/dired.el 13 Mar 2008 02:19:00 -0000
***************
*** 344,356 ****
(defvar dired-warning-face 'dired-warning
"Face name used for a part of a buffer that needs user attention.")
! (defface dired-warn-writable
'((((type w32 pc)) :inherit default) ;; These default to rw-rw-rw.
! (t (:inherit font-lock-warning-face)))
"Face used to highlight permissions of group- and world-writable files."
:group 'dired-faces
:version "22.2")
! (defvar dired-warn-writable-face 'dired-warn-writable
"Face name used for permissions of group- and world-writable files.")
(defface dired-directory
--- 344,356 ----
(defvar dired-warning-face 'dired-warning
"Face name used for a part of a buffer that needs user attention.")
! (defface dired-perm-write
'((((type w32 pc)) :inherit default) ;; These default to rw-rw-rw.
! (t (:inherit font-lock-comment-delimiter-face)))
"Face used to highlight permissions of group- and world-writable files."
:group 'dired-faces
:version "22.2")
! (defvar dired-perm-write-face 'dired-perm-write
"Face name used for permissions of group- and world-writable files.")
(defface dired-directory
***************
*** 414,423 ****
;; fields with keymaps to frob the permissions, somewhat a la XEmacs.
(list (concat dired-re-maybe-mark dired-re-inode-size
"[-d]....\\(w\\)....") ; group writable
! '(1 dired-warn-writable-face))
(list (concat dired-re-maybe-mark dired-re-inode-size
"[-d].......\\(w\\).") ; world writable
! '(1 dired-warn-writable-face))
;;
;; Subdirectories.
(list dired-re-dir
--- 414,423 ----
;; fields with keymaps to frob the permissions, somewhat a la XEmacs.
(list (concat dired-re-maybe-mark dired-re-inode-size
"[-d]....\\(w\\)....") ; group writable
! '(1 dired-perm-write-face))
(list (concat dired-re-maybe-mark dired-re-inode-size
"[-d].......\\(w\\).") ; world writable
! '(1 dired-perm-write-face))
;;
;; Subdirectories.
(list dired-re-dir
--
Juri Linkov
http://www.jurta.org/emacs/
next prev parent reply other threads:[~2008-03-13 2:19 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-13 18:02 23.0.50; Middle ``w´´ in of permissions in dired-mode is red and bold: dired-warning Peter Dyballa
2007-10-13 18:22 ` 23.0.50; Middle ``wŽŽ " martin rudalics
2007-10-13 18:41 ` Peter Dyballa
2007-10-13 19:44 ` 23.0.50; Middle ``w▌▌ " Glenn Morris
2007-10-13 20:37 ` Re: 23.0.50; Middle ``wŽŽ " Eli Zaretskii
2007-10-13 21:30 ` Peter Dyballa
2007-10-13 23:24 ` Miles Bader
2007-10-14 4:10 ` Eli Zaretskii
2007-10-14 4:03 ` Eli Zaretskii
2007-10-14 5:40 ` Re: 23.0.50; Middle ``wZZ " Drew Adams
2007-10-14 20:24 ` Eli Zaretskii
2007-10-14 20:54 ` Drew Adams
2007-10-14 21:20 ` Eli Zaretskii
2007-10-14 21:21 ` 23.0.50; Middle w " Juri Linkov
2007-10-14 22:20 ` Eli Zaretskii
2008-03-13 2:19 ` Juri Linkov [this message]
2008-03-13 4:21 ` Eli Zaretskii
2008-03-13 10:37 ` Juri Linkov
2008-03-13 20:16 ` Eli Zaretskii
2008-03-14 1:07 ` Juri Linkov
[not found] ` <f7ccd24b0803140146m22e5305dy704d7415bc00f8cd@mail.gmail.com>
2008-03-14 8:48 ` Juanma Barranquero
2008-03-14 21:30 ` Juri Linkov
2008-03-14 23:37 ` Juanma Barranquero
2008-03-15 0:17 ` Juri Linkov
2008-03-15 0:26 ` Juanma Barranquero
2008-03-14 12:12 ` Eli Zaretskii
2008-03-14 22:45 ` Chong Yidong
2008-03-15 0:16 ` Juri Linkov
2008-03-15 14:27 ` Eli Zaretskii
2008-03-15 16:20 ` Juri Linkov
2008-03-15 18:30 ` Eli Zaretskii
2008-03-15 14:10 ` Eli Zaretskii
2008-03-15 16:20 ` Juri Linkov
2008-03-15 20:44 ` Stefan Monnier
2008-03-16 14:26 ` martin rudalics
2008-03-16 16:29 ` Juri Linkov
2007-10-15 0:49 ` 23.0.50; Middle ``wZZ " Stefan Monnier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=878x0n1g86.fsf@jurta.org \
--to=juri@jurta.org \
--cc=eliz@gnu.org \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.