From 69f029972384a0ab11e6f98df479363683fbffeb Mon Sep 17 00:00:00 2001 From: Daniel Napora Date: Fri, 28 Jul 2023 17:07:31 +0200 Subject: [PATCH] bigger buttons for OB theme --- bin/colorizer-ob | 2 ++ bin/obtctl | 13 +++++++++++++ .../themes/obbuttons/big-12/close.xbm | 5 +++++ .../themes/obbuttons/big-12/close_hover.xbm | 5 +++++ .../themes/obbuttons/big-12/close_pressed.xbm | 5 +++++ .../themes/obbuttons/big-12/desk.xbm | 5 +++++ .../themes/obbuttons/big-12/desk_hover.xbm | 5 +++++ .../themes/obbuttons/big-12/desk_pressed.xbm | 5 +++++ .../themes/obbuttons/big-12/desk_toggled.xbm | 5 +++++ .../themes/obbuttons/big-12/desk_toggled_hover.xbm | 5 +++++ .../obbuttons/big-12/desk_toggled_pressed.xbm | 5 +++++ .../themes/obbuttons/big-12/iconify.xbm | 5 +++++ .../themes/obbuttons/big-12/iconify_hover.xbm | 5 +++++ .../themes/obbuttons/big-12/iconify_pressed.xbm | 5 +++++ .../mabox-colorizer/themes/obbuttons/big-12/max.xbm | 5 +++++ .../themes/obbuttons/big-12/max_hover.xbm | 5 +++++ .../themes/obbuttons/big-12/max_toggled.xbm | 5 +++++ .../themes/obbuttons/big-12/max_toggled_hover.xbm | 5 +++++ .../themes/obbuttons/big-12/shade.xbm | 5 +++++ .../themes/obbuttons/big-12/shade_hover.xbm | 5 +++++ .../themes/obbuttons/big-12/shade_pressed.xbm | 5 +++++ .../themes/obbuttons/big-12/shade_toggled.xbm | 5 +++++ .../themes/obbuttons/big-12/shade_toggled_hover.xbm | 5 +++++ 23 files changed, 120 insertions(+) create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/close.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/close_hover.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/close_pressed.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/desk.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/desk_hover.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/desk_pressed.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/desk_toggled.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/desk_toggled_hover.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/desk_toggled_pressed.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/iconify.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/iconify_hover.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/iconify_pressed.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/max.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/max_hover.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/max_toggled.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/max_toggled_hover.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/shade.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/shade_hover.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/shade_pressed.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/shade_toggled.xbm create mode 100644 share/mabox-colorizer/themes/obbuttons/big-12/shade_toggled_hover.xbm diff --git a/bin/colorizer-ob b/bin/colorizer-ob index 7b34b16..1fff2f5 100755 --- a/bin/colorizer-ob +++ b/bin/colorizer-ob @@ -260,6 +260,8 @@ out2+=("Tiny,obtctl buttons tiny;$me") out2+=("Normal,obtctl buttons normal;$me") out2+=("Bold,obtctl buttons bold;$me") out2+=("Dots,obtctl buttons dots;$me") +out2+=("^sep()") +out2+=("Big 12px,obtctl buttons big-12;$me") #TEXT out2+=("^tag(titletext)") out2+=("^sep($TITLEBAR_TEXT)") diff --git a/bin/obtctl b/bin/obtctl index 50d76ea..221c857 100755 --- a/bin/obtctl +++ b/bin/obtctl @@ -347,6 +347,19 @@ inactivetextcolor () { buttons () { rm $THEMEDIR/*.xbm cp -a /usr/share/mabox-colorizer/themes/obbuttons/${1}/*.xbm $THEMEDIR/ + #if buttons big check font size also + case "$1" in + big-12) + nspace="http://openbox.org/3.4/rc" + cfg="$HOME/.config/openbox/rc.xml" + SIZE=$(xmlstarlet sel -N a="$nspace" -t -v '/a:openbox_config/a:theme/a:font[@place="ActiveWindow"]/a:size' "$cfg") + if [ "$SIZE" -lt "12" ]; then + xmlstarlet ed -L -N a="$nspace" -u '/a:openbox_config/a:theme/a:font[@place="ActiveWindow"]/a:size' -v "12" "$cfg" + xmlstarlet ed -L -N a="$nspace" -u '/a:openbox_config/a:theme/a:font[@place="InactiveWindow"]/a:size' -v "12" "$cfg" + fi + ;; + *) : ;; + esac } activebuttonscolors () { sd "^window.active.button.*.unpressed.image.color:.*$" "window.active.button.*.unpressed.image.color: ${1}" ${THEMERC} diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/close.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/close.xbm new file mode 100644 index 0000000..e1d9d67 --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/close.xbm @@ -0,0 +1,5 @@ +#define close_width 12 +#define close_height 12 +static unsigned char close_bits[] = { + 0x00, 0x00, 0x06, 0x06, 0x0e, 0x07, 0x9c, 0x03, 0xb8, 0x01, 0x70, 0x00, + 0xe0, 0x00, 0xd8, 0x01, 0x9c, 0x03, 0x0e, 0x07, 0x06, 0x06, 0x00, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/close_hover.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/close_hover.xbm new file mode 100644 index 0000000..de852f9 --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/close_hover.xbm @@ -0,0 +1,5 @@ +#define close_hover_width 12 +#define close_hover_height 12 +static unsigned char close_hover_bits[] = { + 0x00, 0x00, 0x06, 0x06, 0x0e, 0x07, 0x9c, 0x03, 0x98, 0x01, 0x00, 0x00, + 0x00, 0x00, 0x98, 0x01, 0x9c, 0x03, 0x0e, 0x07, 0x06, 0x06, 0x00, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/close_pressed.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/close_pressed.xbm new file mode 100644 index 0000000..371a6b4 --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/close_pressed.xbm @@ -0,0 +1,5 @@ +#define close_pressed_width 12 +#define close_pressed_height 12 +static unsigned char close_pressed_bits[] = { + 0x00, 0x00, 0x06, 0x06, 0x06, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x06, 0x06, 0x06, 0x00, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/desk.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/desk.xbm new file mode 100644 index 0000000..f2b2ff7 --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/desk.xbm @@ -0,0 +1,5 @@ +#define desk_width 12 +#define desk_height 12 +static unsigned char desk_bits[] = { + 0x00, 0x00, 0x9e, 0x07, 0x9e, 0x04, 0x9e, 0x04, 0x9e, 0x07, 0x00, 0x00, + 0x00, 0x00, 0x9e, 0x07, 0x92, 0x04, 0x92, 0x04, 0x9e, 0x07, 0x00, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/desk_hover.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/desk_hover.xbm new file mode 100644 index 0000000..b6059d4 --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/desk_hover.xbm @@ -0,0 +1,5 @@ +#define desk_hover_width 12 +#define desk_hover_height 12 +static unsigned char desk_hover_bits[] = { + 0x00, 0x00, 0x9e, 0x07, 0x9e, 0x07, 0x9e, 0x07, 0x9e, 0x07, 0x00, 0x00, + 0x00, 0x00, 0x9e, 0x07, 0x9e, 0x07, 0x9e, 0x07, 0x9e, 0x07, 0x00, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/desk_pressed.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/desk_pressed.xbm new file mode 100644 index 0000000..f057b9a --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/desk_pressed.xbm @@ -0,0 +1,5 @@ +#define desk_pressed_width 12 +#define desk_pressed_height 12 +static unsigned char desk_pressed_bits[] = { + 0x00, 0x00, 0x02, 0x04, 0x0c, 0x03, 0x0c, 0x03, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x0c, 0x03, 0x0c, 0x03, 0x02, 0x04, 0x00, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/desk_toggled.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/desk_toggled.xbm new file mode 100644 index 0000000..a36dcd4 --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/desk_toggled.xbm @@ -0,0 +1,5 @@ +#define desk_toggled_width 12 +#define desk_toggled_height 12 +static unsigned char desk_toggled_bits[] = { + 0x00, 0x00, 0x9e, 0x07, 0x9e, 0x07, 0x9e, 0x07, 0x9e, 0x07, 0x00, 0x00, + 0x00, 0x00, 0x9e, 0x07, 0x9e, 0x07, 0x9e, 0x07, 0x9e, 0x07, 0x00, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/desk_toggled_hover.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/desk_toggled_hover.xbm new file mode 100644 index 0000000..0dc2f60 --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/desk_toggled_hover.xbm @@ -0,0 +1,5 @@ +#define desk_toggled_hover_width 12 +#define desk_toggled_hover_height 12 +static unsigned char desk_toggled_hover_bits[] = { + 0x00, 0x00, 0x9e, 0x07, 0x9e, 0x04, 0x9e, 0x04, 0x9e, 0x07, 0x00, 0x00, + 0x00, 0x00, 0x9e, 0x07, 0x92, 0x04, 0x92, 0x04, 0x9e, 0x07, 0x00, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/desk_toggled_pressed.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/desk_toggled_pressed.xbm new file mode 100644 index 0000000..876649c --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/desk_toggled_pressed.xbm @@ -0,0 +1,5 @@ +#define desk_toggled_pressed_width 12 +#define desk_toggled_pressed_height 12 +static unsigned char desk_toggled_pressed_bits[] = { + 0x00, 0x00, 0x02, 0x04, 0x0c, 0x03, 0x0c, 0x03, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x0c, 0x03, 0x0c, 0x03, 0x02, 0x04, 0x00, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/iconify.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/iconify.xbm new file mode 100644 index 0000000..891087b --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/iconify.xbm @@ -0,0 +1,5 @@ +#define iconify_width 12 +#define iconify_height 12 +static unsigned char iconify_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x07, 0xfe, 0x07, 0x00, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/iconify_hover.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/iconify_hover.xbm new file mode 100644 index 0000000..53b1ba6 --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/iconify_hover.xbm @@ -0,0 +1,5 @@ +#define iconify_hover_width 12 +#define iconify_hover_height 12 +static unsigned char iconify_hover_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x03, 0xfc, 0x03, 0x00, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/iconify_pressed.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/iconify_pressed.xbm new file mode 100644 index 0000000..21267b6 --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/iconify_pressed.xbm @@ -0,0 +1,5 @@ +#define iconify_pressed_width 12 +#define iconify_pressed_height 12 +static unsigned char iconify_pressed_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x01, 0xf8, 0x01, 0x00, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/max.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/max.xbm new file mode 100644 index 0000000..f397ac5 --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/max.xbm @@ -0,0 +1,5 @@ +#define max_width 12 +#define max_height 12 +static unsigned char max_bits[] = { + 0x00, 0x00, 0xfe, 0x07, 0xfe, 0x07, 0x02, 0x04, 0x02, 0x04, 0x02, 0x04, + 0x02, 0x04, 0x02, 0x04, 0x02, 0x04, 0x02, 0x04, 0xfe, 0x07, 0x00, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/max_hover.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/max_hover.xbm new file mode 100644 index 0000000..6ef5391 --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/max_hover.xbm @@ -0,0 +1,5 @@ +#define max_hover_width 12 +#define max_hover_height 12 +static unsigned char max_hover_bits[] = { + 0xff, 0x0f, 0xff, 0x0f, 0xff, 0x0f, 0x01, 0x08, 0x01, 0x08, 0x01, 0x08, + 0x01, 0x08, 0x01, 0x08, 0x01, 0x08, 0x01, 0x08, 0x01, 0x08, 0xff, 0x0f }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/max_toggled.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/max_toggled.xbm new file mode 100644 index 0000000..81f1831 --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/max_toggled.xbm @@ -0,0 +1,5 @@ +#define max_toggled_width 12 +#define max_toggled_height 12 +static unsigned char max_toggled_bits[] = { + 0xf0, 0x0f, 0xf0, 0x0f, 0x10, 0x08, 0x10, 0x08, 0xff, 0x08, 0xff, 0x08, + 0x81, 0x08, 0x81, 0x0f, 0x81, 0x00, 0x81, 0x00, 0x81, 0x00, 0xff, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/max_toggled_hover.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/max_toggled_hover.xbm new file mode 100644 index 0000000..e2c8cfa --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/max_toggled_hover.xbm @@ -0,0 +1,5 @@ +#define max_toggled_hover_width 12 +#define max_toggled_hover_height 12 +static unsigned char max_toggled_hover_bits[] = { + 0x00, 0x09, 0x00, 0x05, 0x00, 0x03, 0x00, 0x0f, 0xff, 0x00, 0xff, 0x00, + 0x81, 0x00, 0x81, 0x00, 0x81, 0x00, 0x81, 0x00, 0x81, 0x00, 0xff, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/shade.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/shade.xbm new file mode 100644 index 0000000..875fbbd --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/shade.xbm @@ -0,0 +1,5 @@ +#define shade_width 12 +#define shade_height 12 +static unsigned char shade_bits[] = { + 0x00, 0x00, 0x60, 0x00, 0xf0, 0x00, 0xf8, 0x01, 0xfc, 0x03, 0xfe, 0x07, + 0x60, 0x00, 0x60, 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/shade_hover.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/shade_hover.xbm new file mode 100644 index 0000000..eac4e87 --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/shade_hover.xbm @@ -0,0 +1,5 @@ +#define shade_hover_width 12 +#define shade_hover_height 12 +static unsigned char shade_hover_bits[] = { + 0x00, 0x00, 0xfe, 0x07, 0xfe, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/shade_pressed.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/shade_pressed.xbm new file mode 100644 index 0000000..4a39d82 --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/shade_pressed.xbm @@ -0,0 +1,5 @@ +#define shade_pressed_width 12 +#define shade_pressed_height 12 +static unsigned char shade_pressed_bits[] = { + 0x00, 0x00, 0xf8, 0x01, 0xf8, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/shade_toggled.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/shade_toggled.xbm new file mode 100644 index 0000000..af8fcb8 --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/shade_toggled.xbm @@ -0,0 +1,5 @@ +#define shade_toggled_width 12 +#define shade_toggled_height 12 +static unsigned char shade_toggled_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x60, 0x00, 0x60, 0x00, 0x60, 0x00, + 0xfe, 0x07, 0xfc, 0x03, 0xf8, 0x01, 0xf0, 0x00, 0x60, 0x00, 0x00, 0x00 }; diff --git a/share/mabox-colorizer/themes/obbuttons/big-12/shade_toggled_hover.xbm b/share/mabox-colorizer/themes/obbuttons/big-12/shade_toggled_hover.xbm new file mode 100644 index 0000000..686fb9c --- /dev/null +++ b/share/mabox-colorizer/themes/obbuttons/big-12/shade_toggled_hover.xbm @@ -0,0 +1,5 @@ +#define shade_toggled_hover_width 12 +#define shade_toggled_hover_height 12 +static unsigned char shade_toggled_hover_bits[] = { + 0x00, 0x00, 0xfe, 0x07, 0xfe, 0x07, 0x02, 0x04, 0x02, 0x04, 0x02, 0x04, + 0x02, 0x04, 0x02, 0x04, 0xfe, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 };