pywal icon indicating copy to clipboard operation
pywal copied to clipboard

Rofi 1.7.0 breaks Pywal Theming.

Open engageintellect opened this issue 2 years ago • 15 comments

The latest update of Rofi breaks existing themes in .cache/wal/colors-rofi-dark.rasi

engageintellect avatar Sep 02 '21 11:09 engageintellect

Appending this to the file fixes it:

element-text, element-icon {
    background-color: inherit;
    text-color:       inherit;
}

From the rofi github: https://github.com/davatorium/rofi/issues/1397#issuecomment-908683906

epistularum avatar Sep 05 '21 00:09 epistularum

Append to which file? rofi is reading from '~/.cache/wal/colors-rofi-dark.rasi' , and gets overwritten each time pywal is ran and a new colorscheme is generated.

engageintellect avatar Sep 05 '21 01:09 engageintellect

I made a new file in ~/.config/rofi/config.rasi that points to ~/.cache/wal/colors-rofi-dark.rasi and now the colors work. Thank you for getting me on the right track. Now I just have to edit all my scripts to get the sizing correct due to these new flags.

This issue can be removed.

engageintellect avatar Sep 05 '21 01:09 engageintellect

Append to which file? rofi is reading from '~/.cache/wal/colors-rofi-dark.rasi' , and gets overwritten each time pywal is ran and a new colorscheme is generated.

Sorry about that, I'm no programmer and I'm not familiar with the inner workings of rofi. I just referenced this from rofi in hope it would help other people but as you said this seems to be a temporary fix. I'm glad it at least helped you in some way.

epistularum avatar Sep 07 '21 02:09 epistularum

element-text, element-icon {
    background-color: inherit;
    text-color:       inherit;
}

Hello! I have already pushed this fix to the master branch. Updating pywal should fix the issues with Rofi.

Also you can define custom templates in ~/.config/wal/templates. See https://github.com/dylanaraps/pywal/wiki/User-Template-Files

kylosus avatar Sep 07 '21 10:09 kylosus

Thank you! I'll pull down those changes. Thank you for the fast response and commit.

engageintellect avatar Sep 08 '21 19:09 engageintellect

element-text, element-icon {

background-color: inherit;
text-color:       inherit;

}

Hello! I have already pushed this fix to the master branch. Updating pywal should fix the issues with Rofi.

Also you can define custom templates in ~/.config/wal/templates. See https://github.com/dylanaraps/pywal/wiki/User-Template-Files

Still having issues after updating paywal. Adding those lines to the end of ~/.cache/wal/colors-rofi-dark.rasi fixes the issue, but the next time paywal is ran it overwrite those lines and the disappear.

What am I missing?

engageintellect avatar Sep 10 '21 01:09 engageintellect

Ok, I figured it out.

I also needed to append the lines you provided. To;

/usr/lib/Python3.9/site-packages/pywal/templates/colors-rofi-dark.rasi

After doing this (as root) the lines are no longer rewritten each time pywal is ran inside of ~/.cache/wal/colors-rofi-dark.rasi

Thanks for pointing me in the right direction.

engageintellect avatar Sep 10 '21 04:09 engageintellect

A new pywal release would be really helpful for distros to be able to have these changes considering there's non-compatible things with rofi if you're just on the latest released pywal version. @dylanaraps

D-Nice avatar Sep 15 '21 20:09 D-Nice

Also you can define custom templates in ~/.config/wal/templates. See https://github.com/dylanaraps/pywal/wiki/User-Template-Files

I am using a template and I appended the necessary lines.

However when I launch wal again and look at the file in ~/.cache does not have those lines. Am I missing a step?

indeedwatson avatar Nov 02 '21 17:11 indeedwatson

Also you can define custom templates in ~/.config/wal/templates. See https://github.com/dylanaraps/pywal/wiki/User-Template-Files

I am using a template and I appended the necessary lines.

However when I launch wal again and look at the file in ~/.cache does not have those lines. Am I missing a step?

I was having the same problem. I believe I documented my fix in this thread.

Try "sudo updatedb && locate rasi | grep colors | grep dark"

I believe I had to append those same lines to "/use/lib/python3.9/site-packages/pywal/templates/colors-rofi-dark.rasi"

I'm working atm but I can double check what I did to fix this, maybe take a look at my dotfiles as they are now working on multiple machines for me and changing wallpapers/refreshing pywal no longer wipes everything out.

engageintellect avatar Nov 02 '21 19:11 engageintellect

I believe I had to append those same lines to "/use/lib/python3.9/site-packages/pywal/templates/colors-rofi-dark.rasi"

I'm working atm but I can double check what I did to fix this, maybe take a look at my dotfiles as they are now working on multiple machines for me and changing wallpapers/refreshing pywal no longer wipes everything out.

I'm a bit confused by this because this is not where the templates are supposed to be, I have mine in ~/.config/wal/templates/.

Did you arrive at this python directory because the standard way in ~/.config did not work for you? Or was it the first place you tried?

In any case, adding the lines to that file did not help. I don't understand what is the root of this issue, it didn't use to be a problem.

indeedwatson avatar Nov 02 '21 20:11 indeedwatson

I believe I had to append those same lines to "/use/lib/python3.9/site-packages/pywal/templates/colors-rofi-dark.rasi"

I'm working atm but I can double check what I did to fix this, maybe take a look at my dotfiles as they are now working on multiple machines for me and changing wallpapers/refreshing pywal no longer wipes everything out.

I'm a bit confused by this because this is not where the templates are supposed to be, I have mine in ~/.config/wal/templates/.

Did you arrive at this python directory because the standard way in ~/.config did not work for you? Or was it the first place you tried?

In any case, adding the lines to that file did not help. I don't understand what is the root of this issue, it didn't use to be a problem.

Just SSH'd into my machine. Appending those lines to this file is what solved it for me. image

engageintellect avatar Nov 02 '21 20:11 engageintellect

thanks for checking it, the thing is i'm not using that rofi theme, I'm using a custom one with a template.

indeedwatson avatar Nov 02 '21 21:11 indeedwatson

In my case, I had to place this (with double curl-braces)

element-text, element-icon {{ background-color: inherit text-color: inherit }}

in

~/.virtualenvs/lib/python3.11/site-packages/pywal/templates/colors-rofi-dark.rasi ~/.virtualenvs/lib/python3.11/site-packages/pywal/templates/colors-rofi-light.rasi

and this configuration:


configuration {

/* modi: "window,run,ssh";/ modi: "combi,drun,run,ssh,window"; / width: 50;/ / lines: 15;/ / columns: 1;/ / font: "mono 12";/ / bw: 1;/ / location: 0;/ / padding: 5;/ / yoffset: 0;/ / xoffset: 0;/ / fixed-num-lines: true;/ / show-icons: false;/ / terminal: "rofi-sensible-terminal";/ / ssh-client: "ssh";/ / ssh-command: "{terminal} -e {ssh-client} {host} [-p {port}]";/ / run-command: "{cmd}";/ / run-list-command: "";/ / run-shell-command: "{terminal} -e {cmd}";/ / window-command: "wmctrl -i -R {window}";/ / window-match-fields: "all";/ / icon-theme: ;/ / drun-match-fields: "name,generic,exec,categories";/ / drun-show-actions: false;/ / drun-display-format: "{name} [({generic})]";/ / disable-history: false;/ / ignored-prefixes: "";/ / sort: false;/ / sorting-method: ;/ / case-sensitive: false;/ / cycle: true;/ / sidebar-mode: false;/ / eh: 1;/ / auto-select: false;/ / parse-hosts: false;/ / parse-known-hosts: true;/ / combi-modi: "window,run";/ / matching: "normal";/ / tokenize: true;/ / m: "-5";/ / line-margin: 2;/ / line-padding: 1;/ / filter: ;/ / separator-style: "dash";/ / hide-scrollbar: false;/ / fullscreen: false;/ fake-transparency: true; / dpi: -1;/ / threads: 0;/ / scrollbar-width: 8;/ / scroll-method: 0;/ / fake-background: "screenshot";/ / window-format: "{w} {c} {t}";/ / click-to-exit: true;/ / show-match: true;/ / theme: ;/ / color-normal: ;/ / color-urgent: ;/ / color-active: ;/ / color-window: ;/ / max-history-size: 25;/ / combi-hide-mode-prefix: false;/ / matching-negate-char: '-' /* unsupported /;/ /* cache-dir: ;/ / pid: "/run/user/1000/rofi.pid";/ / display-window: ;/ / display-windowcd: ;/ / display-run: ;/ / display-ssh: ;/ / display-drun: ;/ / display-combi: ;/ / display-keys: ;/ / kb-primary-paste: "Control+V,Shift+Insert";/ / kb-secondary-paste: "Control+v,Insert";/ / kb-clear-line: "Control+w";/ / kb-move-front: "Control+a";/ / kb-move-end: "Control+e";/ / kb-move-word-back: "Alt+b,Control+Left";/ / kb-move-word-forward: "Alt+f,Control+Right";/ / kb-move-char-back: "Left,Control+b";/ / kb-move-char-forward: "Right,Control+f";/ / kb-remove-word-back: "Control+Alt+h,Control+BackSpace";/ / kb-remove-word-forward: "Control+Alt+d";/ / kb-remove-char-forward: "Delete,Control+d";/ / kb-remove-char-back: "BackSpace,Shift+BackSpace,Control+h";/ / kb-remove-to-eol: "Control+k";/ / kb-remove-to-sol: "Control+u";/ / kb-accept-entry: "Control+j,Control+m,Return,KP_Enter";/ / kb-accept-custom: "Control+Return";/ / kb-accept-alt: "Shift+Return";/ / kb-delete-entry: "Shift+Delete";/ / kb-mode-next: "Shift+Right,Control+Tab";/ / kb-mode-previous: "Shift+Left,Control+ISO_Left_Tab";/ / kb-row-left: "Control+Page_Up";/ / kb-row-right: "Control+Page_Down";/ / kb-row-up: "Up,Control+p,ISO_Left_Tab";/ / kb-row-down: "Down,Control+n";/ / kb-row-tab: "Tab";/ / kb-page-prev: "Page_Up";/ / kb-page-next: "Page_Down";/ / kb-row-first: "Home,KP_Home";/ / kb-row-last: "End,KP_End";/ / kb-row-select: "Control+space";/ / kb-screenshot: "Alt+S";/ / kb-ellipsize: "Alt+period";/ / kb-toggle-case-sensitivity: "grave,dead_grave";/ / kb-toggle-sort: "Alt+grave";/ / kb-cancel: "Escape,Control+g,Control+bracketleft";/ / kb-custom-1: "Alt+1";/ / kb-custom-2: "Alt+2";/ / kb-custom-3: "Alt+3";/ / kb-custom-4: "Alt+4";/ / kb-custom-5: "Alt+5";/ / kb-custom-6: "Alt+6";/ / kb-custom-7: "Alt+7";/ / kb-custom-8: "Alt+8";/ / kb-custom-9: "Alt+9";/ / kb-custom-10: "Alt+0";/ / kb-custom-11: "Alt+exclam";/ / kb-custom-12: "Alt+at";/ / kb-custom-13: "Alt+numbersign";/ / kb-custom-14: "Alt+dollar";/ / kb-custom-15: "Alt+percent";/ / kb-custom-16: "Alt+dead_circumflex";/ / kb-custom-17: "Alt+ampersand";/ / kb-custom-18: "Alt+asterisk";/ / kb-custom-19: "Alt+parenleft";/ / kb-select-1: "Super+1";/ / kb-select-2: "Super+2";/ / kb-select-3: "Super+3";/ / kb-select-4: "Super+4";/ / kb-select-5: "Super+5";/ / kb-select-6: "Super+6";/ / kb-select-7: "Super+7";/ / kb-select-8: "Super+8";/ / kb-select-9: "Super+9";/ / kb-select-10: "Super+0";/ / ml-row-left: "ScrollLeft";/ / ml-row-right: "ScrollRight";/ / ml-row-up: "ScrollUp";/ / ml-row-down: "ScrollDown";/ / me-select-entry: "MousePrimary";/ / me-accept-entry: "MouseDPrimary";/ / me-accept-custom: "Control+MouseDPrimary";*/

}

/dark theme/ /theme: "~/.cache/wal/colors-rofi-dark.rasi";/ @theme "~/.cache/wal/colors-rofi-dark.rasi"

/Light theme/ /theme: "~/.cache/wal/colors-rofi-light.rasi";/ @theme "~/.cache/wal/colors-rofi-light.rasi"


in:

~/.config/rofi/config.rasi

OrionRandD avatar Oct 20 '23 13:10 OrionRandD