Bug 2267615

Summary: ibus changes the keyboard layout after changing Virtual Keyboard setting at Plasma Wayland
Product: [Fedora] Fedora Reporter: Akira TAGOH <tagoh>
Component: ibusAssignee: fujiwara <tfujiwar>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 40CC: i18n-bugs, shawn.p.huang, tfujiwar
Target Milestone: ---Keywords: i18n
Target Release: ---   
Hardware: Unspecified   
OS: Linux   
Whiteboard:
Fixed In Version: ibus-1.5.30~rc3-1.fc40 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2024-04-19 21:21:47 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Akira TAGOH 2024-03-04 07:35:58 UTC
I installed KDE Live with Japanese keyboard layout. Apparently it works after the installation (e.g. shift+2 introduces "). but it becomes @ as US layout after enabling ibus from the virtual keyboard settings.

Reproducible: Always

Steps to Reproduce:
1.Install KDE Live with Japanese keyboard layout
2.confirm typing on konsole say after the installation
3.Enable IBus from Virtual kayboard and try typing again
Actual Results:  
Keyboard layout will be changed after step 2 from Japanese to US

Expected Results:  
Japanese layout should still be used

Comment 1 fujiwara 2024-03-05 12:15:19 UTC
I guess you don't configure JP layout with ibus-setup.
Probably it would be an RFE.

Comment 2 Akira TAGOH 2024-03-12 03:07:57 UTC
No, I don't. that step hasn't ever needed. I'm wondering what "default" keyboard layout means then.

Comment 3 fujiwara 2024-03-14 04:47:56 UTC
(In reply to Akira TAGOH from comment #2)
> No, I don't. that step hasn't ever needed. I'm wondering what "default"
> keyboard layout means then.

The "default" layout inherits the current session layout.
If you configure 'anthy' only in the GSetting key org.freedesktop.ibus.general preload-engines and start ibus-daemon, ibus-wayland does not change the keymap with 'anthy'.

ibus-wayland configure 'en' layout if you don't configure any layouts by default instead of ibus-panel.
Because I don't know which Xorg keymap or KDE keymap could be the default in Wayland.

Comment 4 Akira TAGOH 2024-03-15 11:14:52 UTC
Without enabling IBus Virtual keyboard, Plasma Wayland recognizes the keyboard layout properly. I guess they simply use the keyboard layout config from systemd as it is.

$ localectl status
System Locale: LANG=ja_JP.UTF-8
    VC Keymap: jp
   X11 Layout: jp
    X11 Model: pc105

Though they also have own layout config in Keyboard->Layout tab in kdesettings but I don't see any layout map there as initial setup.

Comment 5 fujiwara 2024-03-22 01:00:29 UTC
I thought the systemd D-Bus method can get the session keymaps but it would be a RFE while currently ibus-panel runs `setxkbmap -query` to get the session keymaps.
You provides the `localectl` and it would be the nicer way since we can replace `setxkbmap` with `localectl` simply, which is included in the systemd package.
But I think this is still a RFE because `localectl status` does not provide the pre-configured XKB options against `setxkbmap -query` in Xorg and we need to think how to load or set the XKB options in Wayland.

I made the patch to follow your suggestion and it will be implemented to Fedora 40 only as I assume it's a new feature.

Comment 6 Fedora Update System 2024-03-23 01:27:20 UTC
FEDORA-2024-8460f95740 (ibus-1.5.30~rc2-1.fc40) has been submitted as an update to Fedora 40.
https://bodhi.fedoraproject.org/updates/FEDORA-2024-8460f95740

Comment 7 Fedora Update System 2024-03-24 02:23:39 UTC
FEDORA-2024-8460f95740 has been pushed to the Fedora 40 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2024-8460f95740`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2024-8460f95740

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 8 Fedora Update System 2024-03-26 01:19:29 UTC
FEDORA-2024-8460f95740 has been pushed to the Fedora 40 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2024-8460f95740`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2024-8460f95740

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 9 Fedora Update System 2024-04-03 01:21:54 UTC
FEDORA-2024-8460f95740 has been pushed to the Fedora 40 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2024-8460f95740`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2024-8460f95740

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 10 Fedora Update System 2024-04-19 21:21:47 UTC
FEDORA-2024-8460f95740 (ibus-1.5.30~rc3-1.fc40) has been pushed to the Fedora 40 stable repository.
If problem still persists, please make note of it in this bug report.