[haiku-development] Re: Keymaps

  • From: Siarzhuk Zharski <zharik@xxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Wed, 09 May 2012 23:28:48 +0200

Am 09.05.2012 22:46, schrieb John Scipione:
On Wed, May 9, 2012 at 4:38 PM, Siarzhuk Zharski <zharik@xxxxxx <mailto:zharik@xxxxxx>> wrote:

    Am 09.05.2012 01:35, schrieb John Scipione:

        Secondly we need to integrate KeymapSwitcher into Haiku and
        natively
        support multiple keymaps. Apparently this is a must have
        feature for
        Cyrillic users, not just a nice to have, meaning they cannot
        practically use Haiku without native keymap switching support.
        We need
        to add a Deskbar replicant to access the keymap settings. I'm
        not sure
        how KeymapSwitcher currently works, but, I imagine it already has
        this.


    KeymapSwitcher consists of two parts: input_server filter and
    Deskbar replicant. The filter do the following: a) remap the
    Cmd-based shortcuts from Cyrillics to Latin to let them works; b)
    checks for keymap switching shortcut, and send the message to the
    Deskbar replicant. The replicant a) receives the messages from the
    filter, reload keymap file and call some undocumented call in the
    input_server to apply this updated keymap; b) it also tracks the
    currently active team and switches the keymaps in dependecy of it.


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. ;-)

Do you get any kind of visual feedback when this happens?

The 2-letters code in the Deskbar replicant is changed.

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.

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.

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?

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.

---
Kind Regards,
  S.Zharski

Other related posts: