<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.kde.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugs.kde.org/"
          
          maintainer="sysadmin@kde.org"
>

    <bug>
          <bug_id>462274</bug_id>
          
          <creation_ts>2022-11-26 16:02:20 +0000</creation_ts>
          <short_desc>global shortcuts do not work for non-Latin symbols of foreign keyboard layouts, if active application has active input field</short_desc>
          <delta_ts>2025-03-29 14:06:46 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>4</classification_id>
          <classification>Plasma</classification>
          <product>kwin</product>
          <component>input</component>
          <version>5.26.0</version>
          <rep_platform>Debian testing</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>UNCONFIRMED</bug_status>
          <resolution></resolution>
          
          <see_also>https://bugs.kde.org/show_bug.cgi?id=453661</see_also>
    
    <see_also>https://bugs.kde.org/show_bug.cgi?id=375518</see_also>
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>NOR</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>0</everconfirmed>
          <reporter name="George Melikov">mail</reporter>
          <assigned_to name="KWin default assignee">kwin-bugs-null</assigned_to>
          <cc>butirsky</cc>
    
    <cc>eugene.savitsky</cc>
    
    <cc>nate</cc>
    
    <cc>oded</cc>
    
    <cc>xalt7x.service</cc>
          
          <cf_commitlink></cf_commitlink>
          <cf_versionfixedin></cf_versionfixedin>
          <cf_sentryurl></cf_sentryurl>
          <votes>0</votes>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>2178060</commentid>
    <comment_count>0</comment_count>
    <who name="George Melikov">mail</who>
    <bug_when>2022-11-26 16:02:20 +0000</bug_when>
    <thetext>SUMMARY
Global hotkey Shift+Win+2 is broken for me on layout switch to non-English with other Shift+2 symbol (english has @ there, my layout has &quot;) in Wayland , it worked on X11. Wayland just tries to insert &quot;.

Specifically -  it doesn&apos;t work only when there is active input focus, for ex. if input focus is on browser&apos;s url field, Shift+win+2 will be interpreted as shift+2 and &quot; will be added in url field. 
If there is no active input field - global hotkey works.


STEPS TO REPRODUCE
1. Set hotkey Shift+Win+2 on something (for ex - to open n&apos;th desktop)
2. Open Kate, focus on input field, change keyboard layout to anything other that has different simbol on Shift+2 (instead on @)

OBSERVED RESULT
Kate will add this symbol as input.

EXPECTED RESULT
Global hotkey triggered.


SOFTWARE/OS VERSIONS
Operating System: Debian GNU/Linux Testing (Bookworm)
KDE Plasma Version: 5.26.0
KDE Frameworks Version: 5.98.0
Qt Version: 5.15.4
Kernel Version: 5.19.0-2-amd64 (64-bit)
Graphics Platform: Wayland
Processors: 16 × AMD Ryzen 7 5800U with Radeon Graphics
Memory: 15.0 GiB of RAM
Graphics Processor: RENOIR
Manufacturer: HP
Product Name: HP Pavilion Aero Laptop 13-be0xxx

ADDITIONAL INFORMATION
I&apos;ve posted it in https://bugs.kde.org/show_bug.cgi?id=375518 , but looks like it&apos;s a bit different.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2227927</commentid>
    <comment_count>1</comment_count>
    <who name="Vlad Zahorodnii">vlad.zahorodnii</who>
    <bug_when>2023-05-04 08:50:01 +0000</bug_when>
    <thetext>I cannot reproduce it in Plasma 6 when using Ukrainian keyboard layout. Shift+2 produces &quot; too in UA layout.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2270988</commentid>
    <comment_count>2</comment_count>
    <who name="Yevhen Popok">xalt7x.service</who>
    <bug_when>2023-12-04 05:35:21 +0000</bug_when>
    <thetext>(In reply to Vlad Zahorodnii from comment #1)
&gt; I cannot reproduce it in Plasma 6 when using Ukrainian keyboard layout.
&gt; Shift+2 produces &quot; too in UA layout.

I have a similar Wayland-specific issue on both Plasma 5 and Plasma 6.

STEPS TO REPRODUCE:
1. Switch to the Ukrainian layout
2. Open multiple windows of some program
3. Press Alt+&quot;Above_Tab&quot; shortcut to trigger &quot;Walk Through Windows of Current Application&quot; Task Switcher action

OBSERVED RESULT:
KWin Wayland presumably expects specifically Alt+~ combination (and not Alt+ʼ which is produced with input using Ukrainian keyboard layout).
As a workaround I can set Alt+ʼ as an alternative shortcut. On the X11 Session there wan&apos;t need in this.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2285829</commentid>
    <comment_count>3</comment_count>
    <who name="Oded Arbel">oded</who>
    <bug_when>2024-02-04 13:23:18 +0000</bug_when>
    <thetext>I believe I can reproduce the issue on Plasma 6 RC1, my repro is using a different keys (because my non-English layout has the same shift symbols for the number row) but I believe it is the same issue.

Reproduction using &quot;/&quot; key on Hebrew layout - in the SI-1452 the &quot;/&quot; key is on the left-most key of the top character row (&quot;Q&quot; in QWERTY layout):
1. Using the Shortcuts KCM assign some global shortcut to CTRL+/ (in my case I used the &quot;launch Dolphin&quot; shortcut).
2. Activate a window with a text input and put text cursor in the text input (for example, in Firefox on bugs.kde.org).
3. Switch to the Hebrew layout.
4. Press CTRL+/

Expected behavior:
Dolphin should be launched.

Actual behavior:
Nothing happens (or some Firefox action might happen if it is bound to CTRL+.)

On the other hand, pressing CTRL+Q (while in SI-1452 layout) does launch Dolphin.

This is a **very** common issue and - depending on how you look at it - may not actually be a bug. This factors into the discussion in bug #355046: when creating a global shortcut with one layout, when another layout is active - should the global shortcut bind to the physical key on the keyboard or to the character emitted by the key in a specific layout.

Bug #453661 (which Yevhen added a link from to here), is another instance of the same issue - though there its more about how to trigger global shortcuts bound to a character that isn&apos;t actually available in the active layout.

But yes - I think these are all the same issue: IMO global shortcut (in contrast with app-specific shortcuts) should be bound to the physical key, though there are serious technical hurdles to implement this using the current Qt-based approach to global shortcuts.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2286001</commentid>
    <comment_count>4</comment_count>
    <who name="Andrey">butirsky</who>
    <bug_when>2024-02-05 09:14:15 +0000</bug_when>
    <thetext>Oded, in your case the behavior is probably consistent regardless if you have cursor in the text input or not?
This bug is about non-Latin symbols, both &quot;/&quot; and &quot;Q&quot; are Latin.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2287967</commentid>
    <comment_count>5</comment_count>
    <who name="Oded Arbel">oded</who>
    <bug_when>2024-02-11 14:42:11 +0000</bug_when>
    <thetext>(In reply to Andrey from comment #4)
&gt; Oded, in your case the behavior is probably consistent regardless if you
&gt; have cursor in the text input or not?

Correct

&gt; This bug is about non-Latin symbols, both &quot;/&quot; and &quot;Q&quot; are Latin.

I&apos;m not sure I follow - so &quot;/&quot; is a Latin symbol, but &quot;@&quot; and double quotes are not?

I have the exact same issue with &quot;~&quot; - I have it bound in a global shortcut and it does not work if the current window&apos;s active layout is SI-1452 - which maps &quot;;&quot; to the left most key on the number row. To me this issue seems a duplicate of bug #453661.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2287974</commentid>
    <comment_count>6</comment_count>
    <who name="Yevhen Popok">xalt7x.service</who>
    <bug_when>2024-02-11 15:18:41 +0000</bug_when>
    <thetext>(In reply to Oded Arbel from comment #5)
&gt; (In reply to Andrey from comment #4)
&gt; &gt; This bug is about non-Latin symbols, both &quot;/&quot; and &quot;Q&quot; are Latin.
&gt; 
&gt; I&apos;m not sure I follow - so &quot;/&quot; is a Latin symbol, but &quot;@&quot; and double quotes
&gt; are not?

I guess, Andrey is referring to the issue that was described at https://bugs.kde.org/show_bug.cgi?id=375518#c47
I&apos;ll copy it here:
&gt; (In reply to Andrey from comment #46)
&gt; &gt; Essentially, if a key produces different Latin symbol on other layout, the
&gt; &gt; shortcut won&apos;t work (but it will if the symbol is not Latin).
&gt; 
&gt; So basically:
&gt; - if my keyboard has non-Latin (e.g. Cyrillic) symbol on the same place as
&gt; the Latin symbol - shortcut will work
&gt; - If my keyboard has some other Latin symbol - shortcut won&apos;t work and I
&gt; will need to create another shortcut using different keyboard keyboard
&gt; 
&gt; For me &quot;Walk Through Windows of Current Application&quot; is broken by default
&gt; since Ukrainian keyboard layout has another Latin symbol (apostrophe) on the
&gt; same place as QuoteLeft/Grave symbol.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2287979</commentid>
    <comment_count>7</comment_count>
    <who name="Oded Arbel">oded</who>
    <bug_when>2024-02-11 15:44:25 +0000</bug_when>
    <thetext>(In reply to Yevhen from comment #6)
&gt; &gt; For me &quot;Walk Through Windows of Current Application&quot; is broken by default
&gt; &gt; since Ukrainian keyboard layout has another Latin symbol (apostrophe) on the
&gt; &gt; same place as QuoteLeft/Grave symbol.

OK, so for me its the same problem - the default shortcut for &quot;Walk Through Windows of Current Application&quot; is bound to the Latin mapping of the key known in ISO-9995 as E00, that in my non-Latin layout (SI-1452) maps to &quot;;&quot; (I&apos;ve said as much in comment #5), and therefor that action doesn&apos;t work when the active application has the SI-1452 layout active.

This problem does not depend on the active application having an active input field, and is actually bug #453661.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2287985</commentid>
    <comment_count>8</comment_count>
    <who name="Oded Arbel">oded</who>
    <bug_when>2024-02-11 15:55:02 +0000</bug_when>
    <thetext>(In reply to Oded Arbel from comment #7)
&gt; This problem does not depend on the active application having an active
&gt; input field, and is actually bug #453661.

The reason about distinguishing Latin vs. non-Latin characters - as discussed in the aforementioned bug - is that when kwin is trying to figure out if you triggered a global hot key or not, it uses a Qt logic that takes the symbol produced from the layout and tries to figure out &quot;what is the Latin equivalent&quot; because the model is &quot;all global shortcuts are in Latin&quot;. If the symbol emitted is part of the Latin group, then the logic surmises that everything is fine and no translation needed. &quot;apostrophe&quot; and &quot;semi-colon&quot; are included in the Latin layout and therefor whatever shortcut is assigned to E00 will no work in Ukrainian or Hebrew layouts. OTOH, the global shortcut Meta+Q (&quot;show activity list&quot;) that is bound to D01 will work in the Ukrainian layout because &quot;й&quot; is not in the Latin group, while it won&apos;t work in the Hebrew layout because the symbol it maps to D01 is &quot;/&quot; which is in the Latin group.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2411590</commentid>
    <comment_count>9</comment_count>
    <who name="Eugene Savitsky">eugene.savitsky</who>
    <bug_when>2025-03-29 14:06:46 +0000</bug_when>
    <thetext>Is this a dup of https://bugs.kde.org/show_bug.cgi?id=453661?</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>