elementary / switchboard-plug-keyboard

Switchboard Keyboard Plug
GNU General Public License v2.0
28 stars 22 forks source link

Starting IBus with no Input Methods overrides Keyboard Layout #355

Open jeremypw opened 3 years ago

jeremypw commented 3 years ago

What Happened

Switchboard keyboard plug opened with one (non-US) keyboard layout and no Input Methods set. Opened "Input method" tab and turned on IBus daemon

Later noticed that the keyboard layout being used was not the one set in the plug but the standard US one. (Will try and identify at what point this occurs). The entry under the setting org/gnome/desktop/input-sources/sources showed only one keyboard layout - the non-US one that was set in the plug. When an input method was set the correct keyboard layout started to be used again.

Expected Behavior

Starting the IBus daemon with no input method should not override the selected keyboard layout.

Steps to Reproduce

See above under "What Happened"

Logs

Platform Information

Elementary 6 daily

janxkoci commented 1 year ago

This just tripped me up!

I also don't understand, why there are two lists of layouts (one through the iBus and the other without?) - which list am I supposed to use? It seems the iBus one overwrites the other one (the other one looks like the familiar one I know from other systems, so I would use that, but apparently I cannot unless iBus is also activated).

I was avoiding other layouts because they were confusing in eOS (and I only use Czech layout for everything), but my wife needed my computer over the holidays to write some document, so I added new layouts for her. After reboot the keybord was typing nonsense (turned out to be US layout in iBus pane, which I did not set).

jeremypw commented 1 year ago

Not sure, but this may be related to the IBus Preferences setting "Use System Keyboard Layout". I cannot remember whether it was on or off when this issue occurred.

janxkoci commented 1 year ago

I do not see any such setting neither in Switchboard nor in dconf editor :shrug:

jeremypw commented 1 year ago

You need to go into Applications and run "IBus Preferences". There probably should be a way to do this via Settings and/or the Wingpanel.

janxkoci commented 1 year ago

I see. In my case the setting is off.

I think starting the iBus deamon does not explicitly set any "layout" immediatelly. Later (e.g. after reboot/new login), this is "corrected" by setting it to a default value, which seems to be the US layout.

I think the correct way to handle it is to require setting the layout explicitly right after the iBus deamon is activated. (PS: After the reboot, the US layout in the iBus pane was listed twice. That should probably also be fixed.)

There is still the overwriting behaviour, I don't know how to handle that, as I don't really know why two separate ways to handle layouts are even needed. Somebody else will need to chime in on that.