From 28c8924fb1f643bd12d9308195ca24b5c6ab1432 Mon Sep 17 00:00:00 2001 From: Tobias Bengfort Date: Thu, 18 Apr 2024 14:32:23 +0200 Subject: [PATCH] decorations: rm keepBorder --- docs/labwc-actions.5.scd | 6 +++--- docs/labwc-config.5.scd | 5 ----- docs/rc.xml.all | 1 - include/config/rcxml.h | 1 - src/config/rcxml.c | 3 --- src/ssd/ssd.c | 4 ---- src/ssd/ssd_border.c | 8 -------- 7 files changed, 3 insertions(+), 25 deletions(-) diff --git a/docs/labwc-actions.5.scd b/docs/labwc-actions.5.scd index bf28ebba..c26f9a19 100644 --- a/docs/labwc-actions.5.scd +++ b/docs/labwc-actions.5.scd @@ -129,9 +129,9 @@ Actions are used in menus and keyboard/mouse bindings. ** Toggle titlebar of focused window. - If the 'keepBorder' configuration option is enabled (as in the default - configuraton), then a border will be left as the only decorations around the - window. + A border will be left as the only decorations around the window. + If you completely want to remove all server side decorations, use + 'ToggleDecorations' instead. This has no effect on windows that do not have server side decorations. diff --git a/docs/labwc-config.5.scd b/docs/labwc-config.5.scd index 90fb2ef6..0913086e 100644 --- a/docs/labwc-config.5.scd +++ b/docs/labwc-config.5.scd @@ -397,11 +397,6 @@ extending outward from the snapped edge. ** The radius of server side decoration top corners. Default is 8. -** [yes|no] - Keep a small border (and resize area) even for undecorated windows. Default is yes. - - This has no effect on windows that do not have server side decorations. - ** The font to use for a specific element of a window, menu or OSD. Places can be any of: diff --git a/docs/rc.xml.all b/docs/rc.xml.all index 5fdcd346..2ec0a17e 100644 --- a/docs/rc.xml.all +++ b/docs/rc.xml.all @@ -23,7 +23,6 @@ 8 - yes sans 10 diff --git a/include/config/rcxml.h b/include/config/rcxml.h index ff8b8136..c1745923 100644 --- a/include/config/rcxml.h +++ b/include/config/rcxml.h @@ -63,7 +63,6 @@ struct rcxml { /* theme */ char *theme_name; int corner_radius; - bool ssd_keep_border; struct font font_activewindow; struct font font_inactivewindow; struct font font_menuitem; diff --git a/src/config/rcxml.c b/src/config/rcxml.c index 1b14c0a2..f34fb8d7 100644 --- a/src/config/rcxml.c +++ b/src/config/rcxml.c @@ -838,8 +838,6 @@ entry(xmlNode *node, char *nodename, char *content) rc.theme_name = xstrdup(content); } else if (!strcmp(nodename, "cornerradius.theme")) { rc.corner_radius = atoi(content); - } else if (!strcasecmp(nodename, "keepBorder.theme")) { - set_bool(content, &rc.ssd_keep_border); } else if (!strcmp(nodename, "name.font.theme")) { fill_font(nodename, content, font_place); } else if (!strcmp(nodename, "size.font.theme")) { @@ -1146,7 +1144,6 @@ rcxml_init(void) rc.placement_policy = LAB_PLACE_CENTER; rc.xdg_shell_server_side_deco = true; - rc.ssd_keep_border = true; rc.corner_radius = 8; init_font_defaults(&rc.font_activewindow); diff --git a/src/ssd/ssd.c b/src/ssd/ssd.c index c7af568d..b910ae74 100644 --- a/src/ssd/ssd.c +++ b/src/ssd/ssd.c @@ -33,10 +33,6 @@ ssd_thickness(struct view *view) return (struct border){ 0 }; } - if (!rc.ssd_keep_border && view->ssd_titlebar_hidden) { - return (struct border){ 0 }; - } - struct theme *theme = view->server->theme; if (view->maximized == VIEW_AXIS_BOTH) { diff --git a/src/ssd/ssd_border.c b/src/ssd/ssd_border.c index 0db51132..74f29ffa 100644 --- a/src/ssd/ssd_border.c +++ b/src/ssd/ssd_border.c @@ -72,14 +72,6 @@ ssd_border_update(struct ssd *ssd) ssd->margin = ssd_thickness(ssd->view); } - if (!rc.ssd_keep_border && view->ssd_titlebar_hidden) { - if (ssd->border.tree->node.enabled) { - wlr_scene_node_set_enabled(&ssd->border.tree->node, false); - ssd->margin = ssd_thickness(ssd->view); - } - return; - } - if (view->maximized == VIEW_AXIS_BOTH) { return; } else if (!ssd->border.tree->node.enabled) {