From 7e7994dbb2a2c04f55b3c74eb61577c51e9a43ae Mon Sep 17 00:00:00 2001 From: Konstantin Pospelov Date: Thu, 27 Mar 2025 20:11:59 +0100 Subject: swaybar: deduplicate mode and workspace rendering code The render_workspace_button and render_binding_mode_indicator functions are almost the same. This commit extracts the common rendering code into a new render_box function. --- include/swaybar/config.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'include/swaybar') diff --git a/include/swaybar/config.h b/include/swaybar/config.h index 361acd99..ad58b3c3 100644 --- a/include/swaybar/config.h +++ b/include/swaybar/config.h @@ -14,6 +14,11 @@ struct box_colors { uint32_t text; }; +struct box_size { + uint32_t width; + uint32_t height; +}; + struct config_output { struct wl_list link; // swaybar_config::outputs char *name; -- cgit v1.2.3