diff options
author | Dave Davenport <qball@blame.services> | 2022-06-03 19:42:40 +0200 |
---|---|---|
committer | Dave Davenport <qball@blame.services> | 2022-06-06 11:34:49 +0200 |
commit | b676dfe8ad0f805419c1ce5b97f0435bb9342584 (patch) | |
tree | 023fdab01fb0bf967c0e8db92c16a25c357ab9fa /Examples | |
parent | c7776ce9b7fe1bf3f3df1a1ff146fcb7ec830866 (diff) |
[DMenu|Script] Allow theme element updates from script.
Diffstat (limited to 'Examples')
-rwxr-xr-x | Examples/test_script_mode_color.sh | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/Examples/test_script_mode_color.sh b/Examples/test_script_mode_color.sh new file mode 100755 index 00000000..4b0b19db --- /dev/null +++ b/Examples/test_script_mode_color.sh @@ -0,0 +1,28 @@ +#!/usr/bin/env bash + +if [ "$*" = "quit" ] +then + exit 0 +fi + +if [ "$@" ] +then + # Override the previously set prompt. + echo -en "\0theme\x1felement-text { background-color: "$@";}\n" + echo "red" + echo "lightgreen" + echo "lightblue" + echo "lightyellow" + echo "quit" +else + echo -en "\x00prompt\x1ftesting\n" + echo -en "\0urgent\x1f0,2\n" + echo -en "\0active\x1f1\n" + echo -en "\0message\x1fSpecial <b>bold</b>message\n" + + echo "red" + echo "lightgreen" + echo "lightblue" + echo "lightyellow" + echo "quit" +fi |