From a0049f668baa0bdc6578441a6dfe01d8d03928d1 Mon Sep 17 00:00:00 2001 From: John Gebbie Date: Tue, 12 Sep 2023 12:58:11 +0100 Subject: [PATCH] support altgr+ --- doc/dotool.1.scd | 2 +- dotool.go | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/doc/dotool.1.scd b/doc/dotool.1.scd index 516332e..b44a5a0 100644 --- a/doc/dotool.1.scd +++ b/doc/dotool.1.scd @@ -67,7 +67,7 @@ Currently the *type* action has only heuristic support for dead keys. Press and/or release each _CHORD_. A _CHORD_ is a key or a key with modifiers, such as *a*, *shift+a* or *ctrl+shift+a*. - The supported modifiers are *super*, *ctrl*, *alt* and *shift*. + The supported modifiers are *super*, *altgr*, *ctrl*, *alt* and *shift*. Keys can be specified by Linux names, XKB names prefixed with *x:*, or Linux keycodes prefixed with *k:*. The Linux names are diff --git a/dotool.go b/dotool.go index 0f79168..f0618dd 100644 --- a/dotool.go +++ b/dotool.go @@ -97,6 +97,8 @@ func parseChord(keymap *xkb.Keymap, chord string) (Chord, error) { switch strings.ToLower(keys[i]) { case "super": c.Super = true + case "altgr": + c.AltGr = true case "ctrl", "control": c.Ctrl = true case "alt":