From 5c30ffb436280f67715bcb3173ec45664e697614 Mon Sep 17 00:00:00 2001 From: Dylan Araps Date: Fri, 29 Dec 2017 07:32:25 +1100 Subject: [PATCH] general: Remove -a --- pywal/__main__.py | 7 ------- pywal/templates/colors-urxvt.Xresources | 2 ++ pywal/templates/colors.Xresources | 6 ++++-- pywal/util.py | 5 ----- 4 files changed, 6 insertions(+), 14 deletions(-) create mode 100644 pywal/templates/colors-urxvt.Xresources diff --git a/pywal/__main__.py b/pywal/__main__.py index 1de3bf8..5eb74aa 100644 --- a/pywal/__main__.py +++ b/pywal/__main__.py @@ -29,10 +29,6 @@ def get_args(args): description = "wal - Generate colorschemes on the fly" arg = argparse.ArgumentParser(description=description) - arg.add_argument("-a", metavar="\"alpha\"", - help="Set terminal background transparency. \ - *Only works in URxvt*") - arg.add_argument("-b", metavar="background", help="Custom background color to use.") @@ -104,9 +100,6 @@ def process_args(args): scheme_dir = os.path.join(CACHE_DIR, "schemes") shutil.rmtree(scheme_dir, ignore_errors=True) - if args.a: - util.Color.alpha_num = args.a - if args.R: image_file = os.path.join(CACHE_DIR, "wal") diff --git a/pywal/templates/colors-urxvt.Xresources b/pywal/templates/colors-urxvt.Xresources new file mode 100644 index 0000000..ba8937a --- /dev/null +++ b/pywal/templates/colors-urxvt.Xresources @@ -0,0 +1,2 @@ +URxvt*background: [100]{background} +URxvt*borderColor: [100]{background} diff --git a/pywal/templates/colors.Xresources b/pywal/templates/colors.Xresources index ceb9a64..4e35390 100644 --- a/pywal/templates/colors.Xresources +++ b/pywal/templates/colors.Xresources @@ -7,13 +7,13 @@ emacs*background: {background} URxvt*foreground: {foreground} XTerm*foreground: {foreground} UXTerm*foreground: {foreground} -URxvt*background: {background.alpha} +URxvt*background: {background} XTerm*background: {background} UXTerm*background: {background} URxvt*cursorColor: {cursor} XTerm*cursorColor: {cursor} UXTerm*cursorColor: {cursor} -URxvt*borderColor: {background.alpha} +URxvt*borderColor: {background} ! Colors 0-15. *.color0: {color0} @@ -64,3 +64,5 @@ XClock*secondColor: rgba:{color15.xrgba} ! Set depth to make transparency work. URxvt*depth: 32 + +#include "colors-urxvt.Xresources" diff --git a/pywal/util.py b/pywal/util.py index 37df3a8..8fb8255 100644 --- a/pywal/util.py +++ b/pywal/util.py @@ -28,11 +28,6 @@ class Color: """Convert a hex color to xrdb rgba.""" return hex_to_xrgba(self.hex_color) - @property - def alpha(self): - """Add URxvt alpha value to color.""" - return "[%s]%s" % (self.alpha_num, self.hex_color) - @property def strip(self): """Strip '#' from color."""