emacs icon indicating copy to clipboard operation
emacs copied to clipboard

Highlighting from `hl-line-mode` and `set-mark-command` are blending together.

Open YueRen opened this issue 1 year ago • 2 comments

I believe https://github.com/dracula/emacs/commit/62045abe55de683ef328f0081801451a53f33b3b is making the highlighting from hl-line-mode the same as the highlighting from set-mark-command. This means that the highlighting from marking text within a highlighted line becomes invisible, because they blend together seamlessly, which is problematic and very unlike all other emacs themes.

To reproduce:

  1. Go to the start of a line with text
  2. Activate hl-line-mode using M-x hl-line-mode
  3. Activate mark by C-Spc
  4. Move curser to the right, notice there are no visible highlighting
  5. Move curser up and down, notice how both highlights coincide

YueRen avatar Aug 23 '24 11:08 YueRen

Hi, and sorry for the long silence. Thank you very much for your report.

Indeed, on that subject, the change is not good. I wonder if there is something like hl-line-mode on vscode and how they deal with this kind of situation.

I tried to fix that with one of the other (non-canon) background color historically in use in emacs for this theme. Can you check if it does the job, or if I should investigate other color (if possible I’d like to avoid to introduce a new color).

milouse avatar Sep 12 '24 20:09 milouse

Thanks for the change, it looks much better now. The highlighting colours (line vs mark) are different now, though it is still a bit difficult to spot: Screenshot from 2024-09-13 07-45-50

One suggestion: Would it be possible to increase the brightness of the mark highlight slightly so that the contrast between highlight and background is as strong as in the VS Code screenshot in https://github.com/dracula/emacs/issues/106?

Compare 358940512-3e403573-a3c3-4da0-9366-4b9fe2ca2624 vs (hl-line-mode disabled in screenshot below)

Screenshot from 2024-09-13 07-56-22

That should automatically improve the readability with hl-line-mode enabled.

YueRen avatar Sep 13 '24 07:09 YueRen

Hi @YueRen I just added a new commit with a new specific color for the region to try to address the problem of the clash between hl-mode and the region face. Do you mind having a look at the latest version of the main branch? And tell us what do you think of it? Thanks

milouse avatar Jun 23 '25 20:06 milouse

@milouse Thanks a lot, I think it looks much better now. Feel free to close this issue.

YueRen avatar Jun 23 '25 22:06 YueRen

Fixed in 5fd916b588df72bc9e099f8ea5d319a929bdabed

milouse avatar Jun 25 '25 20:06 milouse