adi1090x / rofi

A huge collection of Rofi based custom Applets, Launchers & Powermenus.
GNU General Public License v3.0
6.51k stars 303 forks source link

New features in rofi to improve themeing. #57

Closed DaveDavenport closed 2 years ago

DaveDavenport commented 3 years ago

Let me start with thanking you again for these impressive themes.

In git I (and others) tried to add some options that should make it easier to make incredable themes like these.

Mouse cursor

You can now set the mouse cursor on buttons/textbox:

element,element-text,element-icon, button { 
    cursor: pointer;                
}                                   
entry {                             
    cursor: text;                   
}

Widget Background image

You can set background image (and scale in width,height or both). Or you can set gradients.

window {
    background-image: url("/tmp/i3.png", both);
}
element {
    children: [element-icon, element-text];
    background-image: linear-gradient(to bottom, black/20%, white/20%, black/10%);
}

Icon/Button action

You can make clickable buttons/icons in the UI. For example to make an icon that pastes text in the entry box:

icon-paste {
    expand: false;
    filename: "gtk-paste";
    size: 24;
    vertical-align: 0.5;
    action: "kb-primary-paste";
}

User timeout

If you want to auto-close the UI, this is now possible too:

configuration {
  timeout {
      delay:  15;
      action: "kb-cancel";
  }
}

Both delay and action need to be set. Action can be any of the keybindings as shown in rofi -show keys.

(-timeout-delay 15 -timeout-action "kb-cancel" on commandline.).

Please let me know if there are other additions to the theme engine I can make that helps building themes. I don't want to implement a full CSS set as that is to much work, but there might be things that I can easily implement.

R,

Dave.

adi1090x commented 3 years ago

Hey, Sorry for late response... Got a lot to deal with right now.

Well, these new changes are awesome (I always wanted to have gradient background for rofi)

In addition, I'd suggest something like,... Mouse scroll actions, (not sure if it's possible yet) lets say I've a volume and brightness applet... User just scroll on those applet, or just click the increase/decrease buttons on rofi window and a script run (controlling volume/brightness) update the values of volume and brightness dynamically, without closing the rofi window.

Rest everything is amazing, already. Thanks for the awesome program.