[haiku-bugs] Re: [Haiku] #6442: AltGr should have a separate keycode

  • From: "rq" <trac@xxxxxxxxxxxx>
  • Date: Mon, 23 Aug 2010 14:50:09 -0000

#6442: AltGr should have a separate keycode
-------------------------------+--------------------------------------------
  Reporter:  rq                |         Owner:  pulkomandy
      Type:  enhancement       |        Status:  assigned  
  Priority:  normal            |     Milestone:  R1        
 Component:  Drivers/Keyboard  |       Version:            
Resolution:                    |      Keywords:            
Blocked By:                    |   Has a Patch:  0         
  Platform:  All               |      Blocking:            
-------------------------------+--------------------------------------------

Comment (by rq):

 Replying to [comment:9 pulkomandy]:
 > That's just how a keyboard is meant to work.

 Can we make this statement a little softer? Like "That's how Haiku devs
 expect the keyboard to work"?

 > The AltGr key is meissing from american keyboards,

 I'm confused: do you mean the physical keybaords or our layouts? Because
 like I said, American keyboards DO usually have two Alt keys, and they
 have different scancodes. The only thing they lack are the "Gr" letters on
 the key.


 > What happens is actually that BeOS never used the "Win" key. It happens
 to be mapped as a level 3 shift for now, and that's what should be
 changed, freeing that key for other uses (no one uses it as lelvel3 shift
 anywhere, anyway).

 > There is no way Alt and AltGr doing the same is ever goig to work. Some
 people use keyboards that don't have the windows key (mmu_man still has
 his IBM Model M keyboard, for example). The win-key is a key you are
 allowed to move and do anything with.
 > Making alt and alt-gr do the same thing would get everyone lost. Not
 only BeOS users, but also every azerty user.

 It wouldn't hurt for AZERTY users if you changed the assignment of Alt,
 not AltGr. By the way, the usual Lithuanian layout also makes heavy use of
 AltGr and AltGr+Shift layers, so I really DO know what I'm talking about.

 By the way, I can't understand why retro keyboards should be a deciding
 factor here. I don't mind mmu_man loving IBM Model M, but I don't see a
 reason why such old models should keep Haiku from progressing. Not having
 a Win-key on your keyboard is something you have to opt-in for nowadays,
 not the default. IMO, mmu_man could just go to Keyboard preferences and
 adjust them.

 > It's just plain logical that altgr is the level 3 shift and alt trigger
 keyboard shortcuts. Don't create problems where there isn't any.

 Well, Alt+C for copy doesn't sound logical for me. I agree that it does
 sound logical for long-time BeOS/Haiku users though.

 > The win key should be assigned some meaning that is both useful (because
 we want to use it) and not vital (because it's missing on some keyboards).
 That's the only thing to do, no need to mix up everything else and get
 everyone unable to type under BeOS.

 That's an overstatement. ;)

 > You were annoyed by ctrl and alt being swapped wrt to Windows, and
 that's ok, but it only affects power users that use keyboard shortcuts at
 all. Changing the meaning of AltGr basically prevents reaching 1/3 of the
 characters on an Azerty keyboard. People are going to be lost, and this
 will affect 2-finger typers as well as profesionnal 10-fingers-or-more
 ones.

 Again, I don't intend to change the meaning of AltGr. But I do want to
 change the meaning of Left Alt.

 > AltGr is the level3 shift (or "option" in the current terminology).
 > Alt is the command key.
 > Ctrl is the control key.
 >
 > These are the 3 mandatory keys to use a keyboard and they are always
 there when needed.
 > Old macintosh keyboard don't have AltGr (even today), but they don't
 need it either : their azerty is slightly different (called French (Mac)
 in Haiku), and it uses alt+shift+key for the extra chars, placing them
 elsewhere on the keyboard. This is also the layout used on the amiga and
 similar to the azerty layout of other machines (Amstrad CPC...).

 I'm on a Mac now. Both Opt keys act as AltGr here. Though yes, it seems
 the French layout is slightly different than that in Windows.

 > Now, there is an extra key, that happens to be on most modern Pc
 keyboards : the Win key. Despite being mapped to 'something' in the
 current keymaps, this key has absolutely no use as of now. As this key is
 available on *most* keyboards, but not *all*, you can't rely on it. So you
 can't make it the only option key available, nor the only command key :
 that would just make most BeOS apps shortcuts unuseable for some people.

 For power-users, as you said. I don't think only they use shortcuts, but I
 do believe that the number of keyboards without either a Win, or a Commadn
 key is very very tiny.

 > It can't be assigned to WM actions like stack-and-tile, because these
 aren't even reachable with only the mouse. As we didn't find an use for
 this key, we mapped it in a way that could be useful to some people. In
 American keymap it is the level3 shift, actually not doing anything ; for
 others, the level 3 shift was already mapped to AltGr, so the left Win was
 mapped to level3, while the right Win was mapped to Option. This is the
 only choice that can be played with. Moving any of the other keys would
 prevent use of some part of Haiku for some people.

 You're confusing me again. Right win was mapped to Command I think, not
 Option, because at the moment, Option == Level 3 Shift.

-- 
Ticket URL: <http://dev.haiku-os.org/ticket/6442#comment:10>
Haiku <http://dev.haiku-os.org>
Haiku - the operating system.

Other related posts: