From 7a3658595b8fc96cb95bd13901d1f28935ee056e Mon Sep 17 00:00:00 2001 From: sappigeninja Date: Mon, 19 Oct 2020 13:04:14 +0200 Subject: [PATCH] Created a colors.Xdefines so the user can use pywal colors in ~/.Xresources --- pywal/export.py | 1 + pywal/templates/#colors.Xresources# | 68 +++++++++++++++++++++++++++++ pywal/templates/colors.Xdefines | 23 ++++++++++ 3 files changed, 92 insertions(+) create mode 100644 pywal/templates/#colors.Xresources# create mode 100644 pywal/templates/colors.Xdefines diff --git a/pywal/export.py b/pywal/export.py index 47ea4d2..388ef9e 100644 --- a/pywal/export.py +++ b/pywal/export.py @@ -107,6 +107,7 @@ def get_export_type(export_type): "tty": "colors-tty.sh", "vscode": "colors-vscode.json", "waybar": "colors-waybar.css", + "xdefines" : "colors.Xdefines", "xresources": "colors.Xresources", "xmonad": "colors.hs", "yaml": "colors.yml", diff --git a/pywal/templates/#colors.Xresources# b/pywal/templates/#colors.Xresources# new file mode 100644 index 0000000..018c1e6 --- /dev/null +++ b/pywal/templates/#colors.Xresources# @@ -0,0 +1,68 @@ +! X colors. +! Generated by 'wal' +*foreground: {foreground} +*background: {background} +*.foreground: {foreground} +*.background: {background} +emacs*foreground: {foreground} +emacs*background: {background} +URxvt*foreground: {foreground} +XTerm*foreground: {foreground} +UXTerm*foreground: {foreground} +URxvt*background: {background.alpha} +XTerm*background: {background} +UXTerm*background: {background} +URxvt*cursorColor: {cursor} +XTerm*cursorColor: {cursor} +UXTerm*cursorColor: {cursor} +URxvt*borderColor: {background.alpha} + +! Colors 0-15. +*.color0: {color0} +*color0: {color0} +*.color1: {color1} +*color1: {color1} +*.color2: {color2} +*color2: {color2} +*.color3: {color3} +*color3: {color3} +*.color4: {color4} +*color4: {color4} +*.color5: {color5} +*color5: {color5} +*.color6: {color6} +*color6: {color6} +*.color7: {color7} +*color7: {color7} +*.color8: {color8} +*color8: {color8} +*.color9: {color9} +*color9: {color9} +*.color10: {color10} +*color10: {color10} +*.color11: {color11} +*color11: {color11} +*.color12: {color12} +*color12: {color12} +*.color13: {color13} +*color13: {color13} +*.color14: {color14} +*color14: {color14} +*.color15: {color15} +*color15: {color15} + +! Black color that will not be affected by bold highlighting. +*.color66: {color0} +*color66: {color0} + +! Xclock colors. +XClock*foreground: {foreground} +XClock*background: {background} +XClock*majorColor: rgba:{color15.xrgba} +XClock*minorColor: rgba:{color15.xrgba} +XClock*hourColor: rgba:{color15.xrgba} +XClock*minuteColor: rgba:{color15.xrgba} +XClock*secondColor: rgba:{color15.xrgba} + +! Set depth to make transparency work. +URxvt*depth: 32 diff --git a/pywal/templates/colors.Xdefines b/pywal/templates/colors.Xdefines new file mode 100644 index 0000000..f403b31 --- /dev/null +++ b/pywal/templates/colors.Xdefines @@ -0,0 +1,23 @@ +! X color defines. +! generated by 'wal' + +! Defines: +#define FG {foreground} +#define BG {background} + +#define C0 {color0} +#define C1 {color1} +#define C2 {color2} +#define C3 {color3} +#define C4 {color4} +#define C5 {color5} +#define C6 {color6} +#define C7 {color7} +#define C8 {color8} +#define C9 {color9} +#define C10 {color10} +#define C11 {color11} +#define C12 {color12} +#define C13 {color13} +#define C14 {color14} +#define C15 {color15}