Use the :filter-forced-window
hook for this:
(:add-hook (in jwno/context :hook-manager) :filter-forced-window
(fn [_hwnd _uia exe _desktop]
(string/has-suffix? "\\SomeNaughtyExecutable.exe" exe)))
Here we are checking a window's exe file path, to see if we should force it.
To determine if a window is suitable for forced management, you can invoke the :manage-window
command on it, and see how it reacts. This command is bound to Win + W M
in the example config.
The :filter-forced-window
hook will override the :filter-window
hook.