Skip to content

xkbcommon: make shortcuts persistent across layouts

It can happen the same key has different Latin symbols on different layouts: for example, "`" symbol on English layout, no symbol ("^" dead key) on German and ";" symbol on Czech and Hebrew layouts (for a key below Esc). This creates a problem as these keys will produce different shortcuts depending on what layout is currently active.

This patch makes keys generate the same shortcuts corresponding to the first Latin layout configured in the system, independently of layout actually active.

For example, when having settings like:

setxkbmap -model pc105 -layout "us,de" -option "grp:alt_shift_toggle"

After Alt+Shift, the layout changes to de from us. But Ctrl+"^" still generates Ctrl+` shortcut which is from the first(or default) layout.

[ChangeLog][QtGui][QXkbCommon] make keys produce the same shortcuts independently of current layout

Fixes: QTBUG-108761
Change-Id: Id204a1609ca731f9c56ed3d32847ca18b94be4a0
Reviewed-by: Liang Qi liang.qi@qt.io
Reviewed-by: Andrey Butirsky butirsky@gmail.com
(cherry picked from commit 5e76a956)

Edited by Andrey Butirsky

Merge request reports

Loading