Closed francesco-cadei closed 5 years ago
They aren't normally. I'll need more information; what's your config?
My config:
(setq-default telephone-line-primary-left-separator 'telephone-line-identity-right
telephone-line-primary-right-separator 'telephone-line-identity-left
telephone-line-secondary-left-separator 'telephone-line-identity-hollow-right
telephone-line-secondary-right-separator 'telephone-line-identity-hollow-left)
(custom-set-faces
'(mode-line-inactive
((t (:foreground "grey70" :background "grey17" :box nil))))
'(mode-line
((t (:foreground "grey70" :background "grey22" :box nil))))
'(telephone-line-accent-active
((t (:foreground "grey85" :background "grey6" :box nil))))
'(telephone-line-accent-inactive
((t (:foreground "grey85" :background "grey6" :box nil)))))
(setq-default telephone-line-faces
'((accent . (telephone-line-accent-inactive . telephone-line-accent-active))
(nil . (mode-line . mode-line-inactive))))
(setq-default telephone-line-lhs
'((accent . (telephone-line-vc-segment))
(nil . (telephone-line-buffer-segment))))
(setq-default telephone-line-rhs
'((nil . (telephone-line-misc-info-segment
telephone-line-major-mode-segment))
(accent . (telephone-line-minor-mode-segment
telephone-line-position-segment))))
(telephone-line-mode)
Note that I have setted (accent . (telephone-line-accent-inactive . telephone-line-accent-active)
Yeah, that last line is what inverts it -- the first item in the cons should be the active face. Or are you saying that's your fix for it being inverted already?
You defined the same face for both of them, so I'm not sure what you mean by inverted -- there'd be no way to see if they were swapped. The foreground and background aren't inverted either, here's a pic of describe-face
for me
It is my workaround to fix the inverted default behavior.
You don't have any difference between active
and inactive
in your config (you defined the same face), so how would you know if it's inverted?
I just tried a basic config; I used this init.el
in its entirety:
(add-to-list 'load-path "~/repos/telephone-line")
(require 'telephone-line)
(setq-default telephone-line-primary-left-separator 'telephone-line-identity-right
telephone-line-primary-right-separator 'telephone-line-identity-left
telephone-line-secondary-left-separator 'telephone-line-identity-hollow-right
telephone-line-secondary-right-separator 'telephone-line-identity-hollow-left)
(custom-set-faces
'(mode-line-inactive
((t (:foreground "grey70" :background "grey17" :box nil))))
'(mode-line
((t (:foreground "grey70" :background "grey22" :box nil))))
'(telephone-line-accent-active
((t (:foreground "red" :background "grey6" :box nil))))
'(telephone-line-accent-inactive
((t (:foreground "blue" :background "grey6" :box nil)))))
(setq-default telephone-line-faces
'((accent . (telephone-line-accent-inactive . telephone-line-accent-active))
(nil . (mode-line . mode-line-inactive))))
(setq-default telephone-line-lhs
'((accent . (telephone-line-vc-segment))
(nil . (telephone-line-buffer-segment))))
(setq-default telephone-line-rhs
'((nil . (telephone-line-misc-info-segment
telephone-line-major-mode-segment))
(accent . (telephone-line-minor-mode-segment
telephone-line-position-segment))))
(telephone-line-mode)
So, if your fix works, you'd expect the active
window to have red text, and the inactive
window to have blue text. However, this is the result produced:
So the default behavior is working correctly and the fix inverts it on its own. Do you have something else in your init that could be causing this issue?
Ya, sorry for the time. You are right I have another line in the init.
No problem, glad to help!
telephone-line-accent-inactive
andtelephone-line-accent-active
are inverted