IDE: Keys which do not work in the Default key mapping on Qt6. lazarus / 9-Editor ---------------------------------------------------------------------- dsiders · 2024-06-08 16:05 I recently started using Lazarus on a Linux platform with KDE Plasma 6. Lazarus 3.99 (rev main_3_99-2093-g82cc65e98b)FPC 3.2.2x86_64-linux- qt6AnchorDocking and DockedFormEditor installed Operating System: openSUSE Tumbleweed 20240607KDE Plasma Version: 6.0.5KDE Frameworks Version: 6.2.0Qt Version: 6.7.1Graphics Platform: X11 I found that the following keys, mapped as the "KeyA" settings in the default key mapping, do not do anything: Ctrl + / = Toggle CommentAlt + D = Cut current lineCtrl + E = Find Incremental (TBH I don't know what this is supposed to do...)Ctrl + Shift + M = Insert from Character MapCtrl + Shift + <#> = Toggle marker number # (Ctrl + K + <#> works though) Are these known issues on Linux? Or the Qt6 widgetset? Or, it is worthy of a bug report? Feedback appreciated. ---------------------------------------------------------------------- zeljko · 2024-06-08 19:50 Please fill issue with example project. ---------------------------------------------------------------------- TRon · 2024-06-08 20:17 Would it not be more productive to extend issue 40952 ? (I honestly do not know what is the best route there) ---------------------------------------------------------------------- MarkMLl · 2024-06-08 22:16 I'm uncomfortable here, but I'd suggest that this is something we have to live with and that it's largely a documentation issue. I'm an habitual KDE user, but for the last few years have used a gamer's keypad to beat the IDE into panting submission. There are, quite simply, some key combinations ** which don't work since they've been preempted at a lower level, and about the best that we can do is point users at (a) a way of determining that the window manager (etc.) has claimed them and (b) a way to tell the IDE to use something different. MarkMLl ** As one of the older members of the community, I have strong views on this. Due to inevitable wear and tear, I find the physical (and mental) contortions needed to invoke IDE shortcuts to be between uncomfortable and impossible. I have seen things... I have seen a word processor keyboard designed by a woman for lady typists which had so many key combinations that it put Emacs to shame https://ichef.bbci.co.uk/news/976/cpsprodpb/17C23/p roduction/_104751379_9c0bd761-972a-4627-b74e-fb42307e4466.jpg.webp If a potential operation can't be presented as a selection on a top-of window/screen or dropdown menu, together with a succinct explanation of what it will do, then something (probably the IDE developer) is badly broken. I am not denying that keyboard shortcuts can be useful. But when a user is switching between substantially different application areas- text processing to 2D drafting to 3D design- there are so many conceptual possibilities that trying to remember key combinations for them becomes infeasible. Larry Tesler's rallying cry was "Don't mode me in", but quite frankly history has proven him wrong. If one is working in a word processor or a 2D drawing program, should 3D operations be presented as a distraction? I'm not known for praising MS, but they built the Windows '95 ("Chicago") user interface on top of CUA, and broadly speaking they got it right. At any given time there's probably a half-dozen keyboard shortcuts that the average user can keep in his memory, and if he can't retain those then they (and other significant operations) should be readily accessible via menus. ---------------------------------------------------------------------- dsiders · 2024-06-08 22:36 Quote from: zeljko on June 08, 2024, 09:50:18 pmPlease fill issue with example project. I should have been more specific. The context for the errors (omissions) is the Lazarus IDE. I can write an app to catch those keystrokes though. I'll file a bug report when I complete the demo. ---------------------------------------------------------------------- dsiders · 2024-06-09 05:16 Quote from: dsiders on June 09, 2024, 12:36:39 amQuote from: zeljko on June 08, 2024, 09:50:18 pmPlease fill issue with example project. I should have been more specific. The context for the errors (omissions) is the Lazarus IDE. I can write an app to catch those keystrokes though. I'll file a bug report when I complete the demo. In the process of writing my demo, I discovered that a couple  of the keys work if you know what they really do. I confirmed that the others really do not work. I'm going to update the original bug report for Ctrl+F4 with the new keys and additional information that I've stumbled over. ---------------------------------------------------------------------- dsiders · 2024-06-10 17:21 Just to follow up... The original issue (Ctrl+F4) is caused by global KDE shortcuts to select a virtual desktop . I remapped mine to  Meta+F1..Meta+F4. Works as expected now. Ctrl+/ does not work because QT and LCL do not agree on the virtual key code for the Slash key. QT (all versions) is treating both VK_SLASH and VK_DIVIDE as the same key (VK_DIVIDE). LCL says they should be VK_OEM_2 or VK_LCL_SLASH  (Slash) (?!?) and VK_DIVIDE (NumPad Divide) respectively. Ctrl+Shift+M is a conflict between ecInsertCharacter and ecPluginMultiCaretModeMoveAll key mappings - as far as I can tell. ---------------------------------------------------------------------- Thaddy · 2024-06-10 19:37 That key-taken issue is a long recurring issue for terminals and there is no real good solution. ---------------------------------------------------------------------- dsiders · 2024-06-10 20:33 Quote from: Thaddy on June 10, 2024, 09:37:22 pmThat key-taken issue is a long recurring issue for terminals and there is no real good solution. I'm pretty new to Linux, so I had no idea. Lesson learned. Now I wonder if need to check other global shortcuts... ---------------------------------------------------------------------- Thaddy · 2024-06-11 04:53 Good starting points are: https://itsfoss.com/linux-terminal-shortcuts/ and https://www.wordstar.org/index.php/wsdos-documentation/wsdos- commands/108-wordstar-3-for-dos-commands-reference You will find that many keyboard shortcuts in all kind of environments are based on the wordstar (1978 cp/m) set of shortcuts. That includes the fpc textmode IDE and Lazarus, but also terminals and environments like Qt and GTK. The textmode IDE (fp) strungles often with shortcuts in the terminal. Lazarus GUI programs less so, since it does not need a terminal. But even for GUI pograms there are exceptions. (Some, not all) Terminal commands need to have precedence over the commands of programs running in it, because otherwise the terminal may not work as expected. The problem is that everybody and everything will want to use the wordstar set or a subset of it, because of the familiarity with it for most users. See why it is so hard to get it right? Btw on Windows you can have the same issue if there are a lot of global keyboard shortcuts registered beyond the system reserved ones. I must say I do not know (yet) how to do that on Linux, but for windows I have example code. ---------------------------------------------------------------------- MarkMLl · 2024-06-11 06:29 Quote from: Thaddy on June 11, 2024, 06:53:10 amThe problem is that everybody and everything will want to use the wordstar set or a subset of it, because of the familiarity with it for most users. See why it is so hard to get it right? The problem is that once a key's missing it can be extremely difficult to work out what's swallowing it. My experience is that modifier keys also work different on e.g. Qt and GTK, that right- and left-hand modifiers work different, and so on. I went through it in some detail when writing a wrapper for APL, and also when selecting a key-combination to put a program into "maven mode". MarkMLl