river: Allow applying CSD based on window titles

This extends the `csd-filter-add` command to allow matching on window
titles as well, using a `csd-filter-add kind pattern` syntax. The
following kinds are supported:

  * `title`, which matches window titles
  * `app-id`, which matches app ids

Only exact matches are considered.

As an example following configuration applies client-side decorations to
all windows with the title 'asdf with spaces'.

    riverctl csd-filter-add title 'asdf with spaces'
This commit is contained in:
Ben Fiedler
2021-09-06 15:28:05 +02:00
committed by Isaac Freund
parent 98aed8d47e
commit 5f6428bafe
6 changed files with 79 additions and 33 deletions

View File

@ -28,15 +28,15 @@ over the Wayland protocol.
*close*
Close the focused view.
*csd-filter-add* _app-id_
Add _app-id_ to the CSD filter list. Views with this _app-id_ are
told to use client side decoration instead of the default server
side decoration. Note that this affects both new views, as well as already
existing ones.
*csd-filter-add* *app-id*|*title* _pattern_
Add _pattern_ to the CSD filter list. Views with this _pattern_ are told to
use client side decoration instead of the default server side decoration.
Note that this affects new views as well as already existing ones. Title
updates are not taken into account.
*csd-filter-remove* _app-id_
Remove an _app-id_ from the CSD filter list. Note that this affects both new
views, as well as already existing ones.
*csd-filter-remove* *app-id*|*title* _pattern_
Remove _pattern_ from the CSD filter list. Note that this affects new views
as well as already existing ones.
*exit*
Exit the compositor, terminating the Wayland session.