~protesilaos/lin

4 2

lin-mode in dired buffers with Mac colors doesn't combine well with region colors

Details
Message ID
<m1pmjh26rn.fsf@christiantietze.de>
DKIM signature
pass
Download raw message
Hi,

With these settings, I have per-line highlight in dired with lin, but when I select the file name, the region's color isn't visible. That's a problem to copy parts of a file name or file sizes:

- `modus-themes-region` is '(accented)
- `lin-face` is 'lin-mac-override-fg, for white text on blue line highlight

Would I have to disable `lin-mode` in dired, or is it possible to add a quick fix to faces for this combo in my config?

Thanks!
Christian

-- 
Sent from Bielefeld, Germany <3
https://christiantietze.de -- Programming + Personal
https://zettelkasten.de    -- Creative Knowledge Work
Details
Message ID
<87pmjhvm7u.fsf@protesilaos.com>
In-Reply-To
<m1pmjh26rn.fsf@christiantietze.de> (view parent)
DKIM signature
pass
Download raw message
> From: Christian Tietze <me@christiantietze.de>
> Date: Thu, 09 Jun 2022 17:31:08 +0200

Hello Christian!

> Would I have to disable `lin-mode` in dired, or is it possible to add
> a quick fix to faces for this combo in my config?

These kind of clashes are unfortunate.  We can tweak the colour of the
accented region in the modus-themes, though that might have other
knock-on effects.  Maybe there is another macOS colour you could use?

To disable lin in dired, remove it from the lin-mode-hooks:

    (setq lin-mode-hooks
          '(bongo-mode-hook
            ;; dired-mode-hook
            elfeed-search-mode-hook
            git-rebase-mode-hook
            ibuffer-mode-hook
            ilist-mode-hook
            ledger-report-mode-hook
            log-view-mode-hook
            magit-log-mode-hook
            mu4e-headers-mode
            notmuch-search-mode-hook
            notmuch-tree-mode-hook
            occur-mode-hook
            org-agenda-mode-hook
            tabulated-list-mode-hook))

Then you will need to:

    (add-hook 'dired-mode-hook #'hl-line-mode)

Toggle lin-global-mode for changes to take effect.

-- 
Protesilaos Stavrou
https://protesilaos.com
Details
Message ID
<m135gc23zi.fsf@christiantietze.de>
In-Reply-To
<87pmjhvm7u.fsf@protesilaos.com> (view parent)
DKIM signature
pass
Download raw message
Yes, that makes sense now -- I cannot enable a mode to highlight
lines in a way that suggests per-line selection, and then break with the
expectation by moving the point sideways with a region :)

So hl-line-mode it is. Will test-drive that for a while. Thanks!

-- Christian
Details
Message ID
<m1wndozsnt.fsf@christiantietze.de>
In-Reply-To
<m135gc23zi.fsf@christiantietze.de> (view parent)
DKIM signature
pass
Download raw message
Time to backpedal! It's not lin's fault at all :)

I used this to make lin's colors win over other mode's faces. Was a
quick fix I added a while ago and forgot about.

    ;; From -50 to +50 to override other faces, e.g. neotree links
    (setq hl-line-overlay-priority +50)

Removing that (or reverting to -50) fixes all my problems. (Or at least
those I reported here.)

Cheers!
Christian
Details
Message ID
<875yl8srjn.fsf@protesilaos.com>
In-Reply-To
<m1wndozsnt.fsf@christiantietze.de> (view parent)
DKIM signature
pass
Download raw message
> From: Christian Tietze <me@christiantietze.de>
> Date: Fri, 10 Jun 2022 13:04:06 +0200
>
> Time to backpedal! It's not lin's fault at all :)
>
> I used this to make lin's colors win over other mode's faces. Was a
> quick fix I added a while ago and forgot about.
>
>     ;; From -50 to +50 to override other faces, e.g. neotree links
>     (setq hl-line-overlay-priority +50)
>
> Removing that (or reverting to -50) fixes all my problems. (Or at least
> those I reported here.)

Gotcha!  I remember when I used to change that priority for mct (and I
did read your blog post about those priorities), but I did not think it
would be the culprit here.

-- 
Protesilaos Stavrou
https://protesilaos.com
Reply to thread Export thread (mbox)