Deepin: Shortcut for docking window to side/corner of screen
Solution 1
Following your last answer, and looking at the source code ; I found this using DBUS.
You can create a custom shortcut using the following line as command
qdbus com.deepin.wm /com/deepin/wm com.deepin.wm.TileActiveWindow 1
1
is for left, and 2
for right.
Solution 2
I haven't found a keyboard shortcut yet.
However, if you have a touchpad you swipe sideways with three fingers.
This way the focused window docks to a side of the screen.
If somebody finds a hotkey i would still be happy to know about it!
Solution 3
According to Swizz's answer, I tried to change the number passed to qdbus
and I found the solution for this problem:-
-
From Launcher (start menu), go to Control Center > Keyboard and Language > Shortcuts and you will get this window:-
-
Click Add button that is located at the bottom to add a new custom shortcut:-
-
Add your custom shortcut name, its command and its shortcut key:-
-
To make the window fill the left side, you should pass
1
:-qdbus com.deepin.wm /com/deepin/wm com.deepin.wm.TileActiveWindow 1
-
To make the window fill the right side, you should pass
2
:-qdbus com.deepin.wm /com/deepin/wm com.deepin.wm.TileActiveWindow 2
-
To move the window to the top left side, you should pass
5
:-qdbus com.deepin.wm /com/deepin/wm com.deepin.wm.TileActiveWindow 5
-
To make the window fill the upper side, you should pass
4
:-qdbus com.deepin.wm /com/deepin/wm com.deepin.wm.TileActiveWindow 4
-
To move the window to the top right side, you should pass
6
:-qdbus com.deepin.wm /com/deepin/wm com.deepin.wm.TileActiveWindow 6
-
To move the window to the bottom left side, you should pass
9
:-qdbus com.deepin.wm /com/deepin/wm com.deepin.wm.TileActiveWindow 9
-
To make the window fill the bottom side, you should pass
8
:-qdbus com.deepin.wm /com/deepin/wm com.deepin.wm.TileActiveWindow 8
-
To move the window to the bottom right side, you should pass
10
:-qdbus com.deepin.wm /com/deepin/wm com.deepin.wm.TileActiveWindow 10
-
Related videos on Youtube
ls.
Updated on September 18, 2022Comments
-
ls. over 1 year
I would like to know if there is a shortcut in deepin os for docking a window to a side or corner of the screen. Just like it does when the window is dragged to one edge of the screen.
It doesn't seem to be listed in the shortcut section of the control panel.
Or if there is none, is it somewhere explained how to create on?
-
Swizz almost 6 years@ls. I have read the full source code of the Deepin dbus manager
-
Bit-Man almost 6 yearsSweeping sideways upwards with three fingers the focused window maximizes, doing it again restores it
-
Sergiy Kolodyazhnyy about 5 yearsAs a fellow Deepin and
qdbus
user, I greatly appreciate this answer :) -
cipricus about 5 yearsLogging out/in is needed to see changes.