Bug 443411

Summary: Regression: %w and %t placeholders not available in bell notifications
Product: [Applications] konsole Reporter: Jan Palus <jpalus+kde>
Component: generalAssignee: Konsole Developer <konsole-devel>
Severity: normal CC: avg, jbb, ninjalj, philipp.keck, tumaix
Priority: NOR    
Version: 21.08.1   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In: v22.04.0

Description Jan Palus 2021-10-06 20:37:28 UTC
Moving from https://invent.kde.org/utilities/konsole/-/issues/26

After 67508680 konsole no longer passes widget when triggering notification for bell which in turns makes %w and %t placeholders unavailable.

1. Configure bell notification with execute command having %t placeholder

%t placeholder is not replaced

%t should be replaced with window title
Comment 1 Kurt Hindenburg 2021-10-27 16:18:48 UTC
Jonah Brüchert do you have to look at this?
Comment 2 Kurt Hindenburg 2021-11-02 22:06:21 UTC
Can you explain where you're getting %t?
Comment 3 Jan Palus 2021-11-02 22:25:29 UTC
Not sure if I follow, do you mean where it's replaced (https://invent.kde.org/frameworks/knotifications/-/commit/e25f1f552a9ce6b684e573f26c82cfc76bfcbe18) or how do I use it (for mimicking urgency hint in sway) or perhaps something else?
Comment 4 Kurt Hindenburg 2021-11-02 22:28:48 UTC
OK thanks that makes sense as to why my testing was confusing me
Comment 5 Andriy Gapon 2021-12-10 09:36:36 UTC
I can confirm the same problem with, e.g., '%w' using Konsole 21.08.3.
Comment 6 Bug Janitor Service 2022-01-07 23:52:02 UTC
A possibly relevant merge request was started @ https://invent.kde.org/utilities/konsole/-/merge_requests/573
Comment 7 Kurt Hindenburg 2022-01-11 16:12:27 UTC
Git commit 0fe44c52310a6c276388cf30c81b6fc45a39da32 by Kurt Hindenburg, on behalf of Luis Javier Merino Morán.
Committed on 11/01/2022 at 15:57.
Pushed by hindenburg into branch 'master'.

Pass widget again to KNotification on bell

67508680 refactored TerminalBell out from TerminalDisplay, and in the
process stopped passing the TerminalDisplay widget to KNotification,
which resulted in issues when notifications where configured to mark the
task bar entry or run a command with %w/%t substitutions (for window id
and window title).

Many thanks to Nicole Kleinhoff and Jan Palus who identified the commit
that introduced the regression.
Related: bug 445520, bug 443117

M  +3    -2    src/terminalDisplay/TerminalBell.cpp
M  +2    -1    src/terminalDisplay/TerminalBell.h
M  +1    -1    src/terminalDisplay/TerminalDisplay.cpp

Comment 8 ninjalj 2022-04-19 16:53:34 UTC
*** Bug 452767 has been marked as a duplicate of this bug. ***