Sublime Forum

Using colors from XResources?

#1

I’m trying to figure out if there’s a way when editing a color scheme to use color variables from my system. I use pywal to change system colors on the fly based on the wallpaper, and all of my other important apps are able to utilize these colors except for Sublime. For example, in Polybar, I can set a color to something like ${xrdb:color2}. I can’t seem to get the equivalent to work in a Sublime color scheme. Is there any way to do this?

For example, I don’t want an explicit color in the theme, like this:

<key>background</key>
<string>#1d1f21</string>

I want something like this (the below does not work):

<key>background</key>
<string>${xrdb:color2}</string>

I’m not entirely sure how the color scheme files work or if this is even possible. Is there any way to call these variables? I tried the <variable> flag there rather than <string> but that doesn’t seem to work. What am I doing wrong?

0 Likes