I’m using copy/past function between qubes a lot and I was wondering if there any way to speed up the process instead of pressing 4 different combinations just to get text from one place to another (Ctrl+C > Ctrl+Shift+C > Ctrl+Shift+V > Ctrl+V).
Would it be possible to program single key for copy which would perform Ctrl+C > Ctrl+Shift+C and single key for paste Ctrl+Shift+V > Ctrl+V?
I don’t mind having separate standalone keypad or small usb keys like 3-4 keys you can get from Amazon.
I can not state to have a final solution for you, but I would encourage you to checkout input-remapper which is availablke for fedora 41 / dom0.
You can add macros to keys which is basically what you want.
I copy between qubes a lot too and I’ve set up my forward and backward buttons on my mouse to Ctrl+C and Ctrl+V respectively.
So to copy and paste between qubes I press,
- Forward mouse button, to copy text from origin qube
- Shift + Forward mouse button, to copy text to global clipboard
- Shift + Backward mouse button, to paste text from global clipboard
- Backward mouse button, to paste text to destination qube
It looks long but it takes under 3sec to copy text between qubes.
Good idea. My mouse does not have any additional buttons, but I probably could get one like that.
However it still 4 step action. Since you have extra buttons anyway, forward and backward in this case, would you be able to set up first 2 actions on forward and last two actions on backward? So you only press them once each, without any additional actions keys, such as Shift.
Yes, you can certainly do that. Set 3-key combination to the forward/backwards buttons of the mouse, but I use them for copying within the same qube too, so it’s more convenient for me.
I suggest getting a Logitech mouse and use logid package in sys-usb to communicate with it and configure the buttons.
If you want to use the keyboard, use xdotool - create two simple scripts
and bind them to shortcuts. Script like this:
ID=`xdotool getwindowfocus`
QUBE=$(xprop _QUBES_VMNAME -id $ID|cut -f2 -d\" )
if [[ "$QUBE" == "_QUBES_VMNAME: not found." ]]; then
exit
else
xdotool getactivewindow key --clearmodifiers --delay 50 ctrl+c ctrl+shift+c
fi
I never presume to speak for the Qubes team.
When I comment in the Forum I speak for myself.