Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inactive pills disappear when in minimal mode #85

Open
jesseleite opened this issue Jun 24, 2021 · 3 comments
Open

Inactive pills disappear when in minimal mode #85

jesseleite opened this issue Jun 24, 2021 · 3 comments

Comments

@jesseleite
Copy link

jesseleite commented Jun 24, 2021

I notice that when icons are enabled, if you focus away from the stack, the inactive stack icons lose their background colour and become completely transparent.

This looks fine when icons are enabled, but causes the whole pill to disappear when in minimal mode with icons disabled. Here's a gif showing how the pills disappear when the focus is moved away from the stack...

CleanShot 2021-06-24 at 13 49 10

@b4rlw
Copy link

b4rlw commented Feb 24, 2022

I'm also looking for a fix for this. Any luck?

@mizlan
Copy link

mizlan commented Dec 8, 2023

It has to do with the getColorAttrs, by modifying that function you can do as suits you

@mizlan
Copy link

mizlan commented Dec 9, 2023

diff --git a/stackline/window.lua b/stackline/window.lua
index 82a6eb5..be962f2 100644
--- a/stackline/window.lua
+++ b/stackline/window.lua
@@ -265,20 +265,13 @@ function Window:getColorAttrs(isStackFocused, isWinFocused) -- {{{
             ['false'] = {
                 window = {
                     ['true'] = {
-                        bg = u.extend(u.copy(opts.color), {
-                            alpha = opts.alpha / (opts.dimmer / 1.2),
-                        }),
-                        -- last-focused icon stays full alpha when stack unfocused
+                        bg = u.extend(opts.color, {alpha = opts.alpha}),
                         img = opts.alpha,
                     },
                     ['false'] = {
-                        bg = u.extend(u.copy(opts.color), {
-                            alpha = stackline.manager:getShowIconsState() and 0 or
-                                0.2,
-                        }),
-                        -- unfocused icon has slightly lower alpha when stack also unfocused
-                        img = opts.alpha /
-                            (opts.iconDimmer + (opts.iconDimmer * 0.70)),
+                        bg = u.extend(u.copy(opts.color),
+                            {alpha = opts.alpha / opts.dimmer}),
+                        img = opts.alpha / opts.iconDimmer,
                     },
                 },
             },

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants