I am using Ubuntu 19.04 and I want to create shortcuts like Super+Num_7 to move the active window to top-left corner, Super+Num_4 to move the active window to left, etc, for all 9 numpad numbers.
How to do it?
I am using Ubuntu 19.04 and I want to create shortcuts like Super+Num_7 to move the active window to top-left corner, Super+Num_4 to move the active window to left, etc, for all 9 numpad numbers.
How to do it?
Ubuntu with the GNOME desktop environment does not support quarter tiling (the kind of tiling that you want).
There are some GNOME Shell extensions that offer more advanced tiling options, but I am not sure if they can do exactly what you want. The most popular are:
To install and try them, you have to first install Tweaks and chrome-gnome-shell
by running:
sudo apt install gnome-tweaks chrome-gnome-shell
Then click the extensions' links above, flip the switch to ON and click Install in the popup dialog.
I have also found this Python script from this Stack Overflow question. I haven't tried it yet, but looks like it could work. I will update my answer when I try this.
You could also try another Ubuntu version, like Xubuntu, Kubuntu or Ubuntu-MATE, which all offer options to do what you want (Xubuntu has the shortcuts you need enabled by default; I am not sure about the other environments).
There are built-in-functions with wm
keybindings..
to see what are those functions either use gsettings
command or use dconf-editor tool (to install dconf-editor
run sudo apt install dconf-editor
)
gsettings command:
gsettings list-recursively | grep wm.keybindings | grep move-to
pratap@pratap:~$ gsettings list-recursively | grep wm.keybindings | grep move-to
org.gnome.desktop.wm.keybindings move-to-workspace-7 @as []
org.gnome.desktop.wm.keybindings move-to-workspace-8 @as []
org.gnome.desktop.wm.keybindings move-to-workspace-9 @as []
org.gnome.desktop.wm.keybindings move-to-monitor-left ['<Super>KP_4']
org.gnome.desktop.wm.keybindings move-to-workspace-5 @as []
org.gnome.desktop.wm.keybindings move-to-workspace-6 @as []
org.gnome.desktop.wm.keybindings move-to-workspace-10 @as []
org.gnome.desktop.wm.keybindings move-to-workspace-11 @as []
org.gnome.desktop.wm.keybindings move-to-workspace-12 @as []
org.gnome.desktop.wm.keybindings move-to-center @as []
org.gnome.desktop.wm.keybindings move-to-corner-ne @as []
org.gnome.desktop.wm.keybindings move-to-side-e @as []
org.gnome.desktop.wm.keybindings move-to-workspace-right ['<Control><Shift><Alt>Right']
org.gnome.desktop.wm.keybindings move-to-workspace-up ['<Super><Shift>Page_Up', '<Control><Shift><Alt>Up']
org.gnome.desktop.wm.keybindings move-to-side-n @as []
org.gnome.desktop.wm.keybindings move-to-side-s @as []
org.gnome.desktop.wm.keybindings move-to-side-w ['<Super>KP_4']
org.gnome.desktop.wm.keybindings move-to-corner-nw ['<super>KP_7']
org.gnome.desktop.wm.keybindings move-to-monitor-down ['<Super><Shift>Down']
org.gnome.desktop.wm.keybindings move-to-workspace-left ['<Control><Shift><Alt>Left']
org.gnome.desktop.wm.keybindings move-to-corner-se @as []
org.gnome.desktop.wm.keybindings move-to-monitor-right ['<Super><Shift>Right']
org.gnome.desktop.wm.keybindings move-to-workspace-last ['<Super><Shift>End']
org.gnome.desktop.wm.keybindings move-to-monitor-up ['<Super><Shift>Up']
org.gnome.desktop.wm.keybindings move-to-corner-sw @as []
org.gnome.desktop.wm.keybindings move-to-workspace-down ['<Super><Shift>Page_Down', '<Control><Shift><Alt>Down']
org.gnome.desktop.wm.keybindings move-to-workspace-1 ['<Super><Shift>Home']
org.gnome.desktop.wm.keybindings move-to-workspace-2 @as []
org.gnome.desktop.wm.keybindings move-to-workspace-3 @as []
org.gnome.desktop.wm.keybindings move-to-workspace-4 @as []
pratap@pratap:~$
you can use this syntax ['<Super>KP_4']
to assign the shortcut Super+KP_4
gsettings set org.gnome.desktop.wm.keybindings move-to-side-w "['<Super>KP_4']"
Or use the simple GUI way with dconf-editor