emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Consistent face for keys in *Help* and `substitute-command-keys'


From: Juri Linkov
Subject: Re: Consistent face for keys in *Help* and `substitute-command-keys'
Date: Wed, 10 Mar 2021 19:16:27 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (x86_64-pc-linux-gnu)

>> I completely agree.  I retained "grey85" that was used for foreground,
>> but it's not suitable for background.  But OTOH, "grey95" is almost
>> indistinguishable from the default white background.
>
> The change is fine, but I have a nit/question:
>
> On my screen grey95 is clearly distinguishable while grey90 is too dark
> for comfort.  You report something quite different from that, which
> makes me think that this is perhaps not simply down to taste or
> mere subjective opinion.

When the contrast with the default background is too low, then users
will miss the highlighting, so when the user doesn't see that it has
a different color then it will look as if there is no highlighting at all.
But when it's slightly darker, then I see no problem for users.
So it seems better to have a slightly darker color than to let users
miss highlighting.

To decide what would be a good default, you need to take into accounts
opinions of the majority of users, but also possible problems
that the default could cause to the minority of users.

> Could this be associated with things like differences in luminosity of
> our physical monitors, brightness/contrast settings, X gamma settings
> and what have you?

Maybe, I tried grey95, but when the prompt us at the bottom of the screen:

  foo changed on disk; really edit the buffer? (y, n, r or C-h) 

highlighting of single letters is indistinguishable from the background.

> Is there a way to find an objective measure to decide the better default
> here?  Or should we just make both of us slightly (un)?happy by setting
> the color to e.g. grey92, assuming that the mean between our findings is
> the most scientific we can hope to get and will work somewhat okay-ish
> everywhere, and call it a day?

With grey92 the situation is slightly better.

>> GitHub and GitLab use "grey90" for light and "grey25" for dark,
>> so I changed now accordingly.
>
> BTW, where do you find "grey90"?  They seem to use a lighter background
> than that on the pages I've been looking at.

I deduced this color approximately because on github repos
shades of gray are achieved using transparency.

> Here I see #fafbfc for keys, which is between gray98 and gray99, with an
> added outline:
>
> https://docs.github.com/en/github/getting-started-with-github/keyboard-shortcuts

Indeed, with a border, it's hard to miss highlighting.

> Here I see #f0f0f0 for keys, which is gray94, with no added outline:
>
> https://docs.gitlab.com/ee/user/shortcuts.html

Here there is no border, so they need to use darker colors,
darker than gray95.

So please decide what the default color would be more preferable:
with a border a lighter color could be used, without a border
a darker is needed.

>> When trying to use the style :background "grey90"
>> :box (:line-width 2 :style released-button)
>> the look is much nicer, but at the cost of wasting more vertical space
>> for higher lines.
>
> The look of that is not too bad.  It looks slightly dated perhaps (the
> latest trend is to keep things flat rather than fake 3D) but at least it
> is extremely clear.  It is arguably a more user-friendly choice.

Then it's possible to use flat with rounded borders, without 3D effect.

> I'm not sure that I notice any wasted vertical pixels (we are talking 1
> or 2 of them or something like that, right?) but I didn't measure it.

2 pixels (top and bottom) for line-width 1, 4 pixels for line-width 2.
Especially undesirable when this will increase the height of the minibuffer.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]