Hi beautiful people!
I’m configuring my openbox installation (veeery slowly) and I’m right now working on my rofi configuration. Now, it’s the first time I’m using rofi, so probably I’m doing something very silly on plain wrong but that being said there is a behavior that I cannot understand.
To centralize the color scheme I’ve created a file called colors.rasi where I simply define all the colors
and then import it in the configuration.rasi file with
@import colors.rasi
both files are in the same folder, and apparently it work, but only partially. With that I mean that if I use one of the first 3 colors defined e.g
element selected {
background-color: @BG;
}
it work without problem, and if I change the BG color in colors.rasi it change when I call rofi too. But, there is a but, if I use for example the ON variable, or whatever in the middle, I simply get nothing.
Things I tried:
Changed the name of the starting variables in colors and configuration, nothing changed, first couple works, the others not (as far as I know there are no specific names that you have to use)
checked if I’ve made some typo or if some where tabulated and other spaced: all are formatted the same way and there is no typo (that I can see at least)
add the color in hex directly in the configuration.rasi (tested with ON color) and it works, so is not a problem related to the color itself
In the end, I mean, is not a big problem to have to set the color directly in the configuration, but having more than one it will be a little bit annoying.
I’ve seen this type of configuration used by others and they work, so as stated at the start, surely I’m doing something wrong.
Some of us had been working on Rofi bugs just last week - and the unfortunate answer to this it seems - Rofi is kind of broken. I’ll let some others chime in, but the newest Rofi that was just updated seems to be kind of a mess. . .
Thank you for the reply, so I’ve tested @theme too and it doesn’t works either.
The only way found right now is paste the all colors.rasi content inside the config.rasi. At least that way I can set the color only one time per file and not in every entry.
Hope that the situation will be better in the future, but well, will wait for now.
I’ll leave the thread open in case someone else will have some idea.
Sorry maybe I misunderstood how to do it. I’ve change @import with @theme. Haven’t changed any other stuff. There was else I’d to do to make it works with @theme? If so I’ll try.
i was on that journey after last rofi update to fix eos-i3 rofi menus…
I use same folder for config and colors i do not see a reason to have them in different folders…
You can also have both in one rasi file like the examples come with rofi…
yes exactly … rofi using its own folder preset… where you have rofi/themes and rofi/configs of you do not follow this structure you need to give full path…