From c0dcb20d8c64e757027565a9c307d649094c4b68 Mon Sep 17 00:00:00 2001 From: Ark74 Date: Fri, 8 May 2026 22:57:52 -0600 Subject: [PATCH] lxpanel: fix TPH#256 panel window flooding panel --- ...6-correct_icon-grid_width_under_gtk3.patch | 38 +++++++++++++++++++ helpers/make-lxpanel | 3 +- 2 files changed, 40 insertions(+), 1 deletion(-) create mode 100644 helpers/DATA/lxpanel/patch_changes/006-correct_icon-grid_width_under_gtk3.patch diff --git a/helpers/DATA/lxpanel/patch_changes/006-correct_icon-grid_width_under_gtk3.patch b/helpers/DATA/lxpanel/patch_changes/006-correct_icon-grid_width_under_gtk3.patch new file mode 100644 index 00000000..f66dca27 --- /dev/null +++ b/helpers/DATA/lxpanel/patch_changes/006-correct_icon-grid_width_under_gtk3.patch @@ -0,0 +1,38 @@ +From 57b258a7d703dd94bdcf67c6e92b63b0d402ae43 Mon Sep 17 00:00:00 2001 +From: Ben Walsh +Date: Mon, 7 Feb 2022 07:02:05 +0000 +Subject: [PATCH] Correct icon-grid width under GTK3 + +When opening multiple windows, the Taskbar plugin does not resize the +taskbar buttons if they exceed the available space. Everything to the +right of the taskbar slides off the screen instead. + +Do not set the minimum width to the same value as the natural (i.e. +current) width if the width is constrained by the allocated space, +but set it to the smallest possible value. + +This likely fixes github issue #23, reported by FredericGuilbault, +fixes github issue #29, reported by johnfound, +fixes github issue #63, reported by LiohMoeller, +fixes part of https://bugs.debian.org/1052050, +fixes https://bugs.debian.org/1052376, and +fixes part of https://sourceforge.net/p/lxde/bugs/968. + +(commit message amended by committer) +--- + src/icon-grid.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/icon-grid.c b/src/icon-grid.c +index 2177971e..c0020de3 100644 +--- a/src/icon-grid.c ++++ b/src/icon-grid.c +@@ -392,7 +392,7 @@ static void panel_icon_grid_get_preferred_width(GtkWidget *widget, + } + panel_icon_grid_size_request(widget, &requisition); + if (minimal_width) +- *minimal_width = requisition.width; ++ *minimal_width = ig->constrain_width ? 0 : requisition.width; + if (natural_width) + *natural_width = requisition.width; + } diff --git a/helpers/make-lxpanel b/helpers/make-lxpanel index 9b9da8f4..e646378c 100644 --- a/helpers/make-lxpanel +++ b/helpers/make-lxpanel @@ -17,7 +17,7 @@ # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA # -VERSION=2 +VERSION=3 . ./config @@ -26,6 +26,7 @@ apply_patch_changes # To use the multi-line change log, the message must be enclosed in quotes. changelog "Backport patches from upstream lxpanel to improve stability and functionality: + Correct icon-grid width under GTK3 (TPH#256) Fix scrolling issue in volume plugin (MR#46)/(TPH#218). Handle 'not charging' battery state correctly (MR#53). Prevent wincmd plugin from triggering button clicks incorrectly (MR#78).