public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* AltGr key and mintty
@ 2020-06-07 11:50 Enrico Forestieri
  2020-06-07 12:55 ` Thomas Wolff
  0 siblings, 1 reply; 5+ messages in thread
From: Enrico Forestieri @ 2020-06-07 11:50 UTC (permalink / raw)
  To: cygwin

According to
https://github.com/mintty/mintty/wiki/Keycodes#altgr
when the keyboard layout does not have a keycode for an AltGr
combination, the AltGr key is treated as Alt instead.

I have the following entry in ~/.inputrc

"\e'": "`"			# Alt+' -> `

and, as AltGr+' is not a valid combination in my keyboard layout,
until mintty 3.1.6 by pressing it I was obtaining the wanted backtick
character. However, since mintty 3.1.7, this key combination now
produces nothing. One has to explicitly use LeftALt+' to obtain the
backtick. This is inconvenient because one needs to use both hands,
while AltGr+' can be easily triggered with a single hand.

-- 
Enrico

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: AltGr key and mintty
  2020-06-07 11:50 AltGr key and mintty Enrico Forestieri
@ 2020-06-07 12:55 ` Thomas Wolff
  2020-06-07 13:07   ` Enrico Forestieri
  0 siblings, 1 reply; 5+ messages in thread
From: Thomas Wolff @ 2020-06-07 12:55 UTC (permalink / raw)
  To: cygwin

Am 07.06.2020 um 13:50 schrieb Enrico Forestieri:
> According to
> https://github.com/mintty/mintty/wiki/Keycodes#altgr
> when the keyboard layout does not have a keycode for an AltGr
> combination, the AltGr key is treated as Alt instead.
There were some recent tweaks to ensure consistent handling of AltGr and 
right-Alt and I was not aware of that section in the wiki (it was there 
before my time...).
However, I do not reproduce your particular issue:

> I have the following entry in ~/.inputrc
>
> "\e'": "`"			# Alt+' -> `
>
> and, as AltGr+' is not a valid combination in my keyboard layout,
> until mintty 3.1.6 by pressing it I was obtaining the wanted backtick character.
> However, since mintty 3.1.7, this key combination now produces nothing.
Works for me when switching to US keyboard layout. Which layout do you use?

> One has to explicitly use LeftALt+' to obtain the backtick.
That is the proper way now enforced if the right Alt key is in fact 
AltGr. If it's not, right-Alt+' etc should work alike, as it does here.
> This is inconvenient because one needs to use both hands,
> while AltGr+' can be easily triggered with a single hand.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: AltGr key and mintty
  2020-06-07 12:55 ` Thomas Wolff
@ 2020-06-07 13:07   ` Enrico Forestieri
  2020-06-07 14:42     ` Thomas Wolff
  0 siblings, 1 reply; 5+ messages in thread
From: Enrico Forestieri @ 2020-06-07 13:07 UTC (permalink / raw)
  To: cygwin

On Sun, Jun 07, 2020 at 02:55:25PM +0200, Thomas Wolff wrote:
> Am 07.06.2020 um 13:50 schrieb Enrico Forestieri:
> > According to
> > https://github.com/mintty/mintty/wiki/Keycodes#altgr
> > when the keyboard layout does not have a keycode for an AltGr
> > combination, the AltGr key is treated as Alt instead.
> There were some recent tweaks to ensure consistent handling of AltGr and
> right-Alt and I was not aware of that section in the wiki (it was there
> before my time...).
> However, I do not reproduce your particular issue:
> 
> > I have the following entry in ~/.inputrc
> > 
> > "\e'": "`"			# Alt+' -> `
> > 
> > and, as AltGr+' is not a valid combination in my keyboard layout,
> > until mintty 3.1.6 by pressing it I was obtaining the wanted backtick character.
> > However, since mintty 3.1.7, this key combination now produces nothing.
> Works for me when switching to US keyboard layout. Which layout do you use?

I am using the IT keyboard layout.

> > One has to explicitly use LeftALt+' to obtain the backtick.
> That is the proper way now enforced if the right Alt key is in fact AltGr.
> If it's not, right-Alt+' etc should work alike, as it does here.

All I can say is that it works again when reverting to mintty 3.1.6.

-- 
Enrico

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: AltGr key and mintty
  2020-06-07 13:07   ` Enrico Forestieri
@ 2020-06-07 14:42     ` Thomas Wolff
  2020-06-07 16:14       ` Enrico Forestieri
  0 siblings, 1 reply; 5+ messages in thread
From: Thomas Wolff @ 2020-06-07 14:42 UTC (permalink / raw)
  To: cygwin

Am 07.06.2020 um 15:07 schrieb Enrico Forestieri:
> On Sun, Jun 07, 2020 at 02:55:25PM +0200, Thomas Wolff wrote:
>> Am 07.06.2020 um 13:50 schrieb Enrico Forestieri:
>>> According to
>>> https://github.com/mintty/mintty/wiki/Keycodes#altgr
>>> when the keyboard layout does not have a keycode for an AltGr
>>> combination, the AltGr key is treated as Alt instead.
>> There were some recent tweaks to ensure consistent handling of AltGr and
>> right-Alt and I was not aware of that section in the wiki (it was there
>> before my time...).
>> However, I do not reproduce your particular issue:
>>
>>> I have the following entry in ~/.inputrc
>>>
>>> "\e'": "`"			# Alt+' -> `
>>>
>>> and, as AltGr+' is not a valid combination in my keyboard layout,
>>> until mintty 3.1.6 by pressing it I was obtaining the wanted backtick character.
>>> However, since mintty 3.1.7, this key combination now produces nothing.
>> Works for me when switching to US keyboard layout. Which layout do you use?
> I am using the IT keyboard layout.
The Italian keyboard layout does have an AltGr key:
AltGr+ò → @
AltGr+à → #
AltGr+è → [
AltGr++ → ]
AltGr+é → {
AltGr+* → }
AltGr+' → unmapped by keyboard layout

So the current behaviour is consistent with both the recent changes and 
the Italian layout.
However, if people desire, I can add an option to restore the old 
AltGr/Alt fallback.
Thomas

>>> One has to explicitly use LeftALt+' to obtain the backtick.
>> That is the proper way now enforced if the right Alt key is in fact AltGr.
>> If it's not, right-Alt+' etc should work alike, as it does here.
> All I can say is that it works again when reverting to mintty 3.1.6.
>


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: AltGr key and mintty
  2020-06-07 14:42     ` Thomas Wolff
@ 2020-06-07 16:14       ` Enrico Forestieri
  0 siblings, 0 replies; 5+ messages in thread
From: Enrico Forestieri @ 2020-06-07 16:14 UTC (permalink / raw)
  To: cygwin

On Sun, Jun 07, 2020 at 04:42:03PM +0200, Thomas Wolff wrote:
> Am 07.06.2020 um 15:07 schrieb Enrico Forestieri:
> > On Sun, Jun 07, 2020 at 02:55:25PM +0200, Thomas Wolff wrote:
> > > Am 07.06.2020 um 13:50 schrieb Enrico Forestieri:
> > > > According to
> > > > https://github.com/mintty/mintty/wiki/Keycodes#altgr
> > > > when the keyboard layout does not have a keycode for an AltGr
> > > > combination, the AltGr key is treated as Alt instead.
> > > There were some recent tweaks to ensure consistent handling of AltGr and
> > > right-Alt and I was not aware of that section in the wiki (it was there
> > > before my time...).
> > > However, I do not reproduce your particular issue:
> > > 
> > > > I have the following entry in ~/.inputrc
> > > > 
> > > > "\e'": "`"			# Alt+' -> `
> > > > 
> > > > and, as AltGr+' is not a valid combination in my keyboard layout,
> > > > until mintty 3.1.6 by pressing it I was obtaining the wanted backtick character.
> > > > However, since mintty 3.1.7, this key combination now produces nothing.
> > > Works for me when switching to US keyboard layout. Which layout do you use?
> > I am using the IT keyboard layout.
> The Italian keyboard layout does have an AltGr key:
> AltGr+ò → @
> AltGr+à → #
> AltGr+è → [
> AltGr++ → ]
> AltGr+é → {
> AltGr+* → }
> AltGr+' → unmapped by keyboard layout
> 
> So the current behaviour is consistent with both the recent changes and the
> Italian layout.

I am currently using the following mappings through ~/.inputrc
Alt+' → `
Alt+ì → ~
that mimic the same mapping as on linux (Shift+ì produces ^ by default).

> However, if people desire, I can add an option to restore the old AltGr/Alt
> fallback.

Yes, please, if that's possible. After years of using those key
combinations I always find myself especially using AltGr+ì for
obtainig ~ and discover that it failed only after pressing the
enter key...

-- 
Enrico

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2020-06-07 16:14 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-07 11:50 AltGr key and mintty Enrico Forestieri
2020-06-07 12:55 ` Thomas Wolff
2020-06-07 13:07   ` Enrico Forestieri
2020-06-07 14:42     ` Thomas Wolff
2020-06-07 16:14       ` Enrico Forestieri

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 read-only IMAP folder(s) and NNTP newsgroup(s).