diff --git a/woman/help.py b/woman/help.py index b511c6b27e944a6034d5bb3a3427faadb7bb283e..8de8e1f452e371b4069ca5c905ec8450c963c98d 100644 --- a/woman/help.py +++ b/woman/help.py @@ -112,6 +112,9 @@ c<id>... - select container/window/workspace and ... qy - quit window or all windows in container/workspace kY - xkill window or all windows in container/workspace e - expand container to parent container +s<id/workspace> - swap current workspace with window/container/workspace +d<workspace> - move current workspace to workspace +d<id><key> - move current workspace near to container (see `m`) Shortcuts in search bar (input mode): diff --git a/woman/qt.py b/woman/qt.py index cd3bcb494540892c57086c387369435d17c495a1..fae2974e1baf5519228173c2a73c7ca0ef5d46fa 100755 --- a/woman/qt.py +++ b/woman/qt.py @@ -1266,6 +1266,19 @@ def qt_main(): raise NoSutchKey(key, mod) else: raise NoSutchKey(key, mod) + elif mod == 0 and key == ord('S'): + nd_from = self.focused_widget + with nd_from.marked_context(QColor(255, 0, 0)): + nd_to = await get_container_or_workspace() + if isinstance(nd_to, WorkspaceWidget): + nd_to.swap_with_workspace(nd_from.master, nd_from.slave) + else: + nd_from.move(nd_to, swap=True) + self.load_i3_tree() + elif mod == 0 and key == ord('D'): + nd_from = self.focused_widget + with nd_from.marked_context(QColor(255, 0, 0)): + await ck_move(nd_from) elif mod == 0 and key == ord('R'): # Undocumented for i in self._workspaces.values(): i.metadata_changed()