From be44991def676110bb52dce036f0721e22ea9fef Mon Sep 17 00:00:00 2001 From: tokyo4j Date: Thu, 16 Oct 2025 06:27:20 +0900 Subject: [PATCH 1/5] tests: remove placeholders for arguments --- t/buf-simple.c | 6 ------ t/str.c | 2 -- t/xml.c | 2 -- 3 files changed, 10 deletions(-) diff --git a/t/buf-simple.c b/t/buf-simple.c index ff22aa10..72d9fd40 100644 --- a/t/buf-simple.c +++ b/t/buf-simple.c @@ -12,8 +12,6 @@ static void test_expand_title(void **state) { - (void)state; - struct buf s = BUF_INIT; char TEMPLATE[] = "foo ~/bar"; @@ -58,8 +56,6 @@ test_expand_title(void **state) static void test_buf_add_fmt(void **state) { - (void)state; - struct buf s = BUF_INIT; buf_add(&s, "foo"); @@ -72,8 +68,6 @@ test_buf_add_fmt(void **state) static void test_buf_add_char(void **state) { - (void)state; - const char long_string[] = "123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890"; size_t len = strlen(long_string); diff --git a/t/str.c b/t/str.c index 79debb1c..159f95d3 100644 --- a/t/str.c +++ b/t/str.c @@ -11,8 +11,6 @@ static void test_str_starts_with(void **state) { - (void)state; - assert_true(str_starts_with(" foo", 'f', " \t\r\n")); assert_true(str_starts_with("f", 'f', " \t\r\n")); assert_false(str_starts_with(" foo", '<', " ")); diff --git a/t/xml.c b/t/xml.c index a7be6b87..f4c70744 100644 --- a/t/xml.c +++ b/t/xml.c @@ -100,8 +100,6 @@ struct test_case { static void test_lab_xml_expand_dotted_attributes(void **state) { - (void)state; - for (size_t i = 0; i < ARRAY_SIZE(test_cases); i++) { xmlDoc *doc = xmlReadDoc((xmlChar *)test_cases[i].before, NULL, NULL, 0); From d8260feef20705e0aa84f30c1f898d8061f850db Mon Sep 17 00:00:00 2001 From: tokyo4j Date: Thu, 16 Oct 2025 16:43:59 +0900 Subject: [PATCH 2/5] CI: also run on t/ changes --- .github/workflows/build.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a9ccbb06..b7329c7b 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -18,6 +18,7 @@ on: - 'include/**' - 'protocols/**' - 'clients/**' + - 't/**' - 'scripts/**' - '.github/workflows/**' From 261ec3c5093e89a27916210dbddc8e9e31c1d8d7 Mon Sep 17 00:00:00 2001 From: tokyo4j Date: Mon, 20 Oct 2025 04:02:34 +0900 Subject: [PATCH 3/5] scripts/check: run style check for test files Co-authored-by: @johanmalm --- scripts/check | 2 +- scripts/checkpatch.pl | 1 + t/buf-simple.c | 7 ++++++- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/scripts/check b/scripts/check index 40d48b1e..473fcfdc 100755 --- a/scripts/check +++ b/scripts/check @@ -19,7 +19,7 @@ run_checks () { return $? fi - find src/ include/ clients/ \( -name "*.c" -o -name "*.h" \) -type f -print0 | + find src/ include/ clients/ t/ \( -name "*.c" -o -name "*.h" \) -type f -print0 | nice xargs -0 --max-args 1 --max-procs $(nproc) \ scripts/checkpatch.pl --terse --no-tree --strict --file return $? diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 933dbc59..217536a6 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -5661,6 +5661,7 @@ sub process { $var !~ /^(?:GString|GError|GHashTable)/ && $var !~ /^(?:__FreeBSD__)/ && $var !~ /^(?:RsvgRectangle|RsvgHandle)/ && + $var !~ /^(?:CMUnitTest)/ && $var !~ /^(?:XKB_KEY_XF86Switch_VT_1)/ && #Ignore SI style variants like nS, mV and dB diff --git a/t/buf-simple.c b/t/buf-simple.c index 72d9fd40..d3ebaeb9 100644 --- a/t/buf-simple.c +++ b/t/buf-simple.c @@ -68,7 +68,12 @@ test_buf_add_fmt(void **state) static void test_buf_add_char(void **state) { - const char long_string[] = "123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890"; + static const char long_string[] = + "123456789012345678901234567890123456789012345678901234567890 " + "123456789012345678901234567890123456789012345678901234567890 " + "123456789012345678901234567890123456789012345678901234567890 " + "123456789012345678901234567890123456789012345678901234567890 " + "123456789012345678901234567890123456789012345678901234567890 "; size_t len = strlen(long_string); /* From df3ed58d5b649d6d91b4b405154bfaf430001c82 Mon Sep 17 00:00:00 2001 From: Johan Malm Date: Sun, 19 Oct 2025 18:48:38 +0100 Subject: [PATCH 4/5] NEWS.md: interim update --- NEWS.md | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) diff --git a/NEWS.md b/NEWS.md index 1ae97c51..e7d8b383 100644 --- a/NEWS.md +++ b/NEWS.md @@ -115,6 +115,51 @@ differently [#3099]. There is a pending fix [wlroots-5159]. [unreleased-commits] +### Added + +- With the window-switcher custom field state specifiers 's' and 'S', show 's' + for shaded window @domo141 [#2895] +- Support `xdg-dialog` protocol to enable better handling of modal dialogs @xi + [#3134] +- labnag: add --keyboard-focus option @tokyo4j [#3120] +- Allow window switcher to temporarily unshade windows using config option + `` @Amodio @Consolatis [#3124] +- For the 'classic' style window-switcher, add the following theme options: + - `osd.window-switcher.style-classic.item.active.border.color` + - `osd.window-switcher.style-classic.item.active.bg.color` + @tokyo4j [#3118] + +### Fixed + +- Don't remove newlines when parsing config, menu and XBM because doing so can + cause parser error in some unusual situations like the one shown below. + @tokyo4j [#3148] + +``` + +``` + +### Changed + +- If XML documents (like rc.xml and menu.xml) have an XML declaration (typically + ``), this XML declaration must be the first thing in the + document. In previous versions, line breaks (`\n`) were allowed before due to + the way the files were parsed, but this is approach caused other issues like + [#3145] and is contrary to XML syntax. [#3148] [#3153] +- With the window-switcher custom field state specifiers 's' and 'S', change the + display order from M|m|F to m|s|M|F; and increase the size from three + characters wide to four. @domo141 [#2895] +- Call labnag with on-demand keyboard interactivity by default @tokyo4j [#3120] +- Temporarily unshade windows when switching windows. Restore old behaviour with + `` @Amodio @Consolatis [#3124] +- In the classic style window-switcher, the default color of the selected window + item has been changed to inherit the border color but with 15% opacity + @tokyo4j [#3118] + ## 0.9.2 - 2025-10-10 [0.9.2-commits] @@ -2804,6 +2849,7 @@ Compile with wlroots 0.12.0 and wayland-server >=1.16 [#2886]: https://github.com/labwc/labwc/pull/2886 [#2887]: https://github.com/labwc/labwc/pull/2887 [#2891]: https://github.com/labwc/labwc/pull/2891 +[#2895]: https://github.com/labwc/labwc/pull/2895 [#2909]: https://github.com/labwc/labwc/pull/2909 [#2910]: https://github.com/labwc/labwc/pull/2910 [#2914]: https://github.com/labwc/labwc/pull/2914 @@ -2840,4 +2886,11 @@ Compile with wlroots 0.12.0 and wayland-server >=1.16 [#3081]: https://github.com/labwc/labwc/pull/3081 [#3097]: https://github.com/labwc/labwc/pull/3097 [#3099]: https://github.com/labwc/labwc/pull/3099 +[#3118]: https://github.com/labwc/labwc/pull/3118 +[#3120]: https://github.com/labwc/labwc/pull/3120 +[#3124]: https://github.com/labwc/labwc/pull/3124 [#3126]: https://github.com/labwc/labwc/pull/3126 +[#3134]: https://github.com/labwc/labwc/pull/3134 +[#3145]: https://github.com/labwc/labwc/pull/3145 +[#3148]: https://github.com/labwc/labwc/pull/3148 +[#3153]: https://github.com/labwc/labwc/pull/3153 From 1e406dd6495bf7e55dccc2e75578efee79a0df18 Mon Sep 17 00:00:00 2001 From: Johan Malm Date: Sun, 19 Oct 2025 19:41:24 +0100 Subject: [PATCH 5/5] labnag: use overlay layer by default ...so that the dialog is still visible when some client is using fullscreen mode. --- docs/labwc-config.5.scd | 1 + src/config/rcxml.c | 1 + 2 files changed, 2 insertions(+) diff --git a/docs/labwc-config.5.scd b/docs/labwc-config.5.scd index ca167b62..00817898 100644 --- a/docs/labwc-config.5.scd +++ b/docs/labwc-config.5.scd @@ -286,6 +286,7 @@ this is for compatibility with Openbox. --border-bottom-size 1 \\ --button-border-size 3 \\ --keyboard-focus on-demand \\ + --layer overlay \\ --timeout 0 ``` diff --git a/src/config/rcxml.c b/src/config/rcxml.c index a966577c..6ed1522b 100644 --- a/src/config/rcxml.c +++ b/src/config/rcxml.c @@ -1646,6 +1646,7 @@ post_processing(void) "--border-bottom-size 1 " "--button-border-size 3 " "--keyboard-focus on-demand " + "--layer overlay " "--timeout 0"); } if (!rc.fallback_app_icon_name) {