Greatly simplify rofi stylesheet

Noticed rofi wasn't handling selection highlights properly any more. In
troubleshooting found the stylesheet was massively over-complicated
since it was a copy of a less simple stylesheet in its origins.
Simplified and fixed the bug.
This commit is contained in:
Trysdyn Black 2021-12-28 01:11:10 -08:00
parent bc476def8b
commit 7657770a22

View file

@ -22,9 +22,6 @@
* { * {
background-color: @base00; background-color: @base00;
alt-background-color: @base01;
urgent-background-color: @base08;
urgent-text-color: @base00;
text-color: @base05; text-color: @base05;
border-color: @base02; border-color: @base02;
spacing: 2; spacing: 2;
@ -34,18 +31,21 @@ window {
border: 1; border: 1;
padding: 5; padding: 5;
} }
mainbox { mainbox {
border: 0; border: 0;
padding: 0; padding: 0;
} }
message { message {
border: 1px dash 0px 0px ; border: 1px dash 0px 0px ;
padding: 1px ; padding: 1px ;
} }
textbox { textbox {
background-color: @alt-background-color; background-color: @background-color;
border: 2px solid;
} }
listview { listview {
fixed-height: 0; fixed-height: 0;
border: 0; border: 0;
@ -53,61 +53,39 @@ listview {
scrollbar: true; scrollbar: true;
padding: 0; padding: 0;
} }
element { element {
border: 0; border: 0;
padding: 1px ; padding: 1px;
} }
element normal.normal {
} selected {
element normal.urgent {
background-color: @urgent-background-color;
text-color: @urgent-text-color;
}
element normal.active {
}
element selected.normal {
background-color: @border-color; background-color: @border-color;
} }
element selected.urgent {
background-color: @text-color;
text-color: @urgent-background-color;
}
element selected.active {
background-color: @border-color;
}
element alternate.normal {
}
element alternate.urgent {
background-color: @urgent-background-color;
text-color: @urgent-text-color;
}
element alternate.active {
}
scrollbar { scrollbar {
width: 4px ;
border: 0; border: 0;
handle-color: @text-color; handle-color: @text-color;
handle-width: 8px ; handle-width: 8px ;
padding: 0; padding: 2;
} }
sidebar { sidebar {
border: 2px dash 0px 0px ; border: 2px dash 0px 0px ;
border-color: @border-color; border-color: @border-color;
} }
button { button {
spacing: 0; spacing: 0;
} }
button selected {
background-color: @selected-normal-background;
text-color: @selected-normal-foreground;
}
inputbar { inputbar {
spacing: 0px; spacing: 0px;
padding: 1px ; padding: 1px;
children: [ prompt,textbox-prompt-colon,entry,case-indicator ]; children: [ prompt,textbox-prompt-colon,entry,case-indicator ];
border: 2px solid; border: 2px solid;
border-color: @selected-normal-background;
} }
case-indicator { case-indicator {
spacing: 0; spacing: 0;
background-color: inherit; background-color: inherit;
@ -117,10 +95,12 @@ entry {
spacing: 0; spacing: 0;
background-color: inherit; background-color: inherit;
} }
prompt { prompt {
spacing: 0; spacing: 0;
background-color: inherit; background-color: inherit;
} }
textbox-prompt-colon { textbox-prompt-colon {
expand: false; expand: false;
str: ":"; str: ":";