[haiku-development] Re: Keymaps

  • From: John Scipione <jscipione@xxxxxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Wed, 9 May 2012 18:37:31 -0400

On Wed, May 9, 2012 at 5:28 PM, Siarzhuk Zharski <zharik@xxxxxx> wrote:

>  Am 09.05.2012 22:46, schrieb John Scipione:
> Can you also switch your keymap graphically using the replicant or do you
> need to use the modifier?
> Practically only the shortcut is used, because the keymaps are team (task)
> sensitive - so using context menu of replicant will switch the keymap of
> Deskbar but not the keymap of application user wants. ;-)

I see... I understand why it currently doesn't work because it will switch
the keymap used by Deskbar instead of the app you want, but it should be
made to work in a graphical way.

> Do you get any kind of visual feedback when this happens?
> The 2-letters code in the Deskbar replicant is changed.

Sounds okay to me.

> I would imagine showing the flag as the replicant icon would be what you'd
> want to do, say the flag of the Russian Federation for Russian, the Old
> Glory for US, etc.
> Hm... Which flag are you going to show on my non-standard German-based
> Belarusian Phonetic keymap, for example? :-D  Or how to distinguish
> Cyrillic and Latin Belarusian keymaps?
I personally do not like using flags as identifier. IMO it looks
> unprofessional and smells on Linux too much. Too obvious to pretend on any
> signs of taste in such "design", IMO. ;-)  So I prefer Win-like 2-letters
> codes. so both indication ways may be provided for user, I think.

Well, perhaps have the flag and 2 letter code. Use the Belarusian flag for
all Belarusian derived keymaps, and only change the 2 letter code when you
switch between them. But, if you are switching between US and Russian, the
flag would change. I don't know, perhaps the flag is redundant and
unnecessary, it is just how I imagined it working in my head. Mac OS X
shows the flag, they just repeat the same flag for related keymaps, They
may show a code too, maybe not, idk.

> And what is the modifier used to switch your keymap? Is it one way only or
> can you switch backwards or forwards?
> I do not think that we should incorporate current KeymapSwitcher in any
> way - it was designed as workaround for BeOS  but Haiku can support this
> functionality in less perversive way. So in KS there are 3 hard-coded
> combinations and was [not fully successfull] attempt to reuse CapsLock and
> NumLock. The simply, one-way cyclic switching was used.

Okay, perhaps a single key combo is all that is needed with one-way cycling.

Certainly it should be a system reserved key combo like Ctrl+tab is for
Twitcher. I think Mac OS X uses Cmd+Space. Although, they also use that for
Spotlight... I'd think maybe something like Ctrl+Alt+Left and
Ctrl+Alt+Right could work, to go forwards and backwards between the
keymaps, something like that. Or we could use Cmd+space. I'll leave it up
to whomever decides to do the work.

> Can you change the modifiers used to switch your keymap? Does the
> interface allow you to add/remove keymaps?
> Have you tried to install the KS from optional packages and play a bit to
> know more about it?

No, but I will. I am completely ignorant about it, I have never had a
reason to install it until now. I have however looked at the source code...

> Does keymap switching ever happen automatically like when you are Activate
> certain apps or is it triggered manually only?
> Every team (application, process, task) has it's own active keymap, so
> changing focus may automatically change the keymap too.
> And again - we need _native_ solution but not just cleared variation of
> the KemapSwitcher "perversy". ;-) As far as I remember, I have already
> described possible way of implementation in the previous thread.  The only
> addition was made keymap view-sensitive.

I vaguely recall that discussion which is why I asked, something about per
app keymap switching.

Anyway, you are right, we need a native solution, not equal to but better
than what KeymapSwitcher currently provides.

John Scipione

Other related posts: