From: Ryan El Kochta <relkochta@gmail.com>
To: qemu-devel@nongnu.org, kraxel@redhat.com
Cc: Ryan El Kochta <relkochta@gmail.com>
Subject: [Qemu-devel] [PATCH 0/1] input-linux: customizable grab toggle keys v5
Date: Wed, 23 Jan 2019 16:45:54 -0500 [thread overview]
Message-ID: <20190123214555.12712-1-relkochta@gmail.com> (raw)
This patch adds a new option to the input-linux object:
grab-toggle=[key-combo]
The key combination can be one of the following:
* ctrl-ctrl
* alt-alt
* meta-meta
* scrolllock
* ctrl-scrolllock
The user can pick any of these key combinations. The VM's grab
of the evdev device will be toggled when the key combination is
pressed.
Any invalid setting will result in an error. No setting will
result in the current default of ctrl-ctrl.
The right and left ctrl key both work for Ctrl-Scrolllock.
If scrolllock is selected as one of the grab-toggle keys, it
will be entirely disabled and not passed to the guest at all.
This is to prevent enabling it while attempting to leave or enter
the VM. On the host, scrolllock can be disabled using xmodmap.
First, find the modifier that Scroll_Lock is bound to:
$ xmodmap -pm
Then, remove Scroll_Lock from it, replacing modX with the modifier:
$ xmodmap -e 'remove modX = Scroll_Lock'
If Scroll_Lock is not bound to any modifier, it is already disabled.
To save the changes, add them to your xinitrc.
Ryan El Kochta (1):
input-linux: customizable grab toggle keys v5
qapi/ui.json | 10 ++++++++
ui/input-linux.c | 66 +++++++++++++++++++++++++++++++++++++++++++++---
2 files changed, 73 insertions(+), 3 deletions(-)
--
2.20.1
next reply other threads:[~2019-01-23 21:48 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-23 21:45 Ryan El Kochta [this message]
2019-01-23 21:45 ` [Qemu-devel] [PATCH 1/1] input-linux: customizable grab toggle keys v5 Ryan El Kochta
2019-01-24 9:47 ` [Qemu-devel] [PATCH 0/1] " Gerd Hoffmann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190123214555.12712-1-relkochta@gmail.com \
--to=relkochta@gmail.com \
--cc=kraxel@redhat.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).