[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Consistent face for keys in *Help* and `substitute-command-keys'
From: |
Stefan Kangas |
Subject: |
Re: Consistent face for keys in *Help* and `substitute-command-keys' |
Date: |
Sat, 6 Mar 2021 22:03:05 -0500 |
Eli Zaretskii <eliz@gnu.org> writes:
> Thanks, I see only minor nits, this can go in once they are taken care
> of.
Thank you for reviewing the patch.
>> +*** Keybindings in 'help-mode' use the new `help-key-binding' face.
>
> I think this should mention substitute-command-keys, and say that any
> text that is run through that function will be propertized. I'd also
> mention the effect on tooltips there.
How about this:
*** Keybindings in 'help-mode' use the new 'help-key-binding' face.
This face is added by 'substitute-command-keys' to any "\[command]"
substitution. The return value of that function should consequently
be assumed to be a propertized string.
Note that the new face will also be used in tooltips. When using the
GTK toolkit, this is only true if 'x-gtk-use-system-tooltips' is t.
>> --- a/lisp/help.el
>> +++ b/lisp/help.el
>> @@ -104,8 +104,8 @@ help-map
>> (define-key map "R" 'info-display-manual)
>> (define-key map "s" 'describe-syntax)
>> (define-key map "t" 'help-with-tutorial)
>> - (define-key map "w" 'where-is)
>> (define-key map "v" 'describe-variable)
>> + (define-key map "w" 'where-is)
>> (define-key map "q" 'help-quit)
>
> Why the change in the order?
It's just to make them alphabetical. If it is too minor, I can leave it
out.
>> + (insert (propertize "M-x "
>> + 'face 'help-key-binding
>> + 'font-lock-face
>> 'help-key-binding))
>
> Why are we fontifying "M-x" here?
I understand "M-x" to be part of the keybinding for that command, so I
think it makes sense to use the same face for that part too. IOW,
rather than fontifying only "apropos" in "M-x apropos" we fontify the
whole string.
- Re: Consistent face for keys in *Help* and `substitute-command-keys', (continued)
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Eli Zaretskii, 2021/03/05
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Stefan Kangas, 2021/03/05
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Eli Zaretskii, 2021/03/05
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Stefan Kangas, 2021/03/05
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Eli Zaretskii, 2021/03/05
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Stefan Kangas, 2021/03/05
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Eli Zaretskii, 2021/03/06
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Stefan Kangas, 2021/03/06
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Stefan Kangas, 2021/03/06
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Eli Zaretskii, 2021/03/06
- Re: Consistent face for keys in *Help* and `substitute-command-keys',
Stefan Kangas <=
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Eli Zaretskii, 2021/03/07
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Stefan Kangas, 2021/03/07
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Eli Zaretskii, 2021/03/07
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Juri Linkov, 2021/03/08
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Stefan Kangas, 2021/03/08
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Juri Linkov, 2021/03/08
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Stefan Kangas, 2021/03/09
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Juri Linkov, 2021/03/10
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Stefan Kangas, 2021/03/10
- Re: Consistent face for keys in *Help* and `substitute-command-keys', Juri Linkov, 2021/03/10