You are not logged in.
Pages: 1
So I know there exists a way to create shortcuts to tile my window to the left, right, corners by going to
window-manager->keyboard..
What I need (if possible) is a way to create 2 or more shortcuts for the same action
So for example, I can tile my window to the bottom left with Super and then the NumPad 1 ..
But, what if I want to add one more keyboard shortcut for the same action.
I know I can try to write some 'complex' script using wmctrl .. but it's not easy when I am using multiple monitors..
Somehow, xfce4 / xfmwm4's shortcuts work beautifully.. I am trying to find out the 'underlying' command that gets called so I can then 'run' that command and add my own shortcuts in the 'keyboard shortcuts' .. or if there is any other way..
I am an xubuntu / xfce user since many years and this would be amazing if it's possible.
Thanks for the help in advance. My first time posting, don't know about etiquette and rules.. hope I didn't break any.
Offline
First and foremost, welcome to our wonderful forum!
The "underlying" configuration is stored in Xfconf.
xfconf-query --channel xfce4-keyboard-shortcuts --list --verbose
Should list all of the shortcuts.
The back-end itself is stored in ~/.config/xfce/xfconf/xfce-perchannel-xml/xfce4-keyboard-shortcuts.xml
Remember to edit the subject of your topic to include the [SOLVED] tag once you're satisfied with the answers or have found a solution (in which case, don't forget to share it as well), so that other members of the community can quickly refer to it and save their time. Pretty please!
Offline
Hey Kbar, thanks for the welcome .. Alright let me check out the back-end stuff and see if I can find what I am looking for..
But either way thank you for responding!
I knew about the xfconf and was dabling with it .. but couldn't get anywhere..
Offline
Okay, so I had also found this backend file too .. didn't realize it was the same file you were referring to.. The parts I am interested in are
<property name="<Primary><Super>KP_Up" type="string" value="tile_up_key"/>
<property name="<Primary><Super>KP_Down" type="string" value="tile_down_key"/>
<property name="<Primary><Super>KP_Left" type="string" value="tile_left_key"/>
<property name="<Primary><Super>KP_Right" type="string" value="tile_right_key"/>
<property name="<Primary><Super>KP_Home" type="string" value="tile_up_left_key"/>
Usually,
the same file would have something like this:
<property name="<Alt><Super>1" type="string" value="bash /home/ace/Documents/scripts/ws.sh 0"/>
<property name="<Alt><Super>2" type="string" value="bash /home/ace/Documents/scripts/ws.sh 1"/
Where an actual command is tied to a keyboard shortcut.. whereas, in the above (the thing I'm interested in)
You would notice these are xfce4 internal 'functions' .. that are being called to conduct the tiling effect.
I have also found the source-code that implements it.
Wondering if there is a terminal command that is exposed that can trigger the same tiling effect (tile top, tile bottom right etc)
Which are being indicated by the values "tile_down_key" .. etc
So here's why I'm saying this to make this clear so you are able to help me (if a solution exists)
I can choose my shortcut keys by going to settings->windows-manager->keyboard shortcuts .. and then add keyboard shortcuts to the tiling..
The only problem with that is.. I want to be able to add an additional set of keyboard shortcuts for the same function.
And this UI (the window->manager->keyboard-shortcuts UI), doesn't allow me to duplicate the function and add an additional shortcut..
Unlike say the regular keyboard-shortcuts UI (settings->keyboard->application shortcuts) where I can add the same command multiple times and have multiple short-cut keys..
You may wonder why I'd want multiple shortcut keys.. well cuz my go to shortcut keys involve the numpad (but when I'm on my laptop and not attached to my full sized keyboard), I'd like an alternative shortcut keys for the tiling .. that doesn't include the numpad (and unfortunately the laptop i have doesn't have an exclusive numpad or even a 'soft numpad' using the Fn key)
Hope I have clarified my needs (wants rather)
Offline
Perhaps you can try adding additional properties with the same value?
xfconf-query --channel xfce4-keyboard-shortcuts --create --property '<Super>Down' --type string --set tile_down_key
I didn't test it but worth a try I guess?
Remember to edit the subject of your topic to include the [SOLVED] tag once you're satisfied with the answers or have found a solution (in which case, don't forget to share it as well), so that other members of the community can quickly refer to it and save their time. Pretty please!
Offline
I just tested it and it just overwrote on top of the old shortcut.
I think what you can do is write a script that monitors the USB connection to your keyboard and then adjusts these settings on the fly. Kind of like a toggle.
Remember to edit the subject of your topic to include the [SOLVED] tag once you're satisfied with the answers or have found a solution (in which case, don't forget to share it as well), so that other members of the community can quickly refer to it and save their time. Pretty please!
Offline
Sorry was in a meeting ... I had tried that.. adding multiple rows in that file, but didn't work... Yep, I guess I will have to write a script using wmctrl or something..
Anyway, thanks a lot for the help!
Offline
You could just use xdotool to echo the shortcut keys of the main shortcut and assign it to another shortcut.
xdotool key Super+Right
...assuming that Super+Right is the shortcut set in Window Manager Settings, and assign this command to, for example, Ctrl+Right.
Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki | Community | Contribute ---
Offline
Pages: 1
[ Generated in 0.014 seconds, 8 queries executed - Memory usage: 553.91 KiB (Peak: 571.2 KiB) ]