Bug 479963

Summary: Meta + PageUp (or PageDown) using the numeric keypad... does not work
Product: [Plasma] kwin Reporter: Ganton <kubry>
Component: generalAssignee: KWin default assignee <kwin-bugs-null>
Status: RESOLVED WORKSFORME    
Severity: normal CC: duha.bugs, toni.asensi
Priority: NOR    
Version: 5.27.8   
Target Milestone: ---   
Platform: Kubuntu   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Ganton 2024-01-17 23:16:58 UTC
Dear Plasma developers,

Some people have to use different keyboards, where (for example, in laptops) the PageDown and PageUp keys are in different places (or there are no dedicated PageDown or PageUp keys).

Then, using the numeric keypad is very useful, as its PageDown and PageUp keys are in its expected place. Additionally, to use those keys, people do not have to press Fn or remember any other key combination.

However, to minimize windows in Plasma, pressing Meta + the PageDown key of the numeric keypad does not work. The same happens trying to use Meta + PageUp on numeric keypad.
Comment 1 Ganton 2024-01-17 23:18:13 UTC
POSSIBLY USEFUL INFORMATION

On https://invent.kde.org/plasma/kwin/-/blob/master/src/useractions.cpp we can see: 
    initShortcut("Window Maximize", i18n("Maximize Window"),
        Qt::META | Qt::Key_PageUp, &Workspace::slotWindowMaximize);
and
    initShortcut("Window Minimize", i18n("Minimize Window"),
        Qt::META | Qt::Key_PageDown, &Workspace::slotWindowMinimize);

For another case, on https://bugs.kde.org/show_bug.cgi?id=346806 a developer used:
    QKeySequence(Qt::KeypadModifier + Qt::Key_PageUp))

So, for example
    initShortcut("Window Maximize", i18n("Maximize Window"),
        QKeySequence(Qt::Key_Meta + Qt::KeypadModifier + Qt::Key_PageUp), &Workspace::slotWindowMaximize);
and
    initShortcut("Window Maximize", i18n("Maximize Window"),
        QKeySequence(Qt::Key_Meta + Qt::Key_PageUp), &Workspace::slotWindowMaximize);
could work? (both key combinations would have to be accepted).
Comment 2 duha.bugs 2024-01-18 16:33:28 UTC
Works for me. 
Please make sure you have not accidentally activated Num Lock. Do the numeric PageDown and PageUp keys work in other places like text editors for you?

Also please provide your system information.

Operating System: Arch Linux 
KDE Plasma Version: 6.0.80
KDE Frameworks Version: 5.249.0
Qt Version: 6.6.1
Kernel Version: 6.7.0-arch3-1 (64-bit)
Graphics Platform: Wayland
Processors: 12 × AMD Ryzen 5 2600X Six-Core Processor
Memory: 15,6 GiB of RAM
Graphics Processor: AMD Radeon RX 580 Series
Comment 3 Ganton 2024-01-18 18:05:58 UTC
> Do the numeric PageDown and PageUp keys work in other places like text editors for you?

Yes, in text editors, web browsers, etc.
        
I'm using KDE Plasma 5.27.8, KF 5.110.0, Kubuntu 23.10 and Qt 5.15.10.
Comment 4 Ganton 2024-01-19 11:12:46 UTC
Thanks, Duha. Does    Ctrl + Alt + numeric Del    work for you in your (unreleased) Plasma 6?
Comment 5 duha.bugs 2024-01-19 13:54:44 UTC
Ctrl + Alt + numeric Del does also work for me.

 I also tried with:
KDE Plasma Version: 5.27.10
KDE Frameworks Version: 5.114.0
Qt Version: 5.15.12
Kernel Version: 6.7.0-arch3-1 (64-bit)

Works as expected.
Comment 6 Toni Asensi Esteve 2024-01-21 12:34:41 UTC
Thanks, Duha. I've done some other tests and (using the numeric keypad) that did not work (Meta + PageUp, Meta + PageDown, Ctrl+Alt+Del) with:
- the Live CD of Debian 12.04 (debian-live-12.4.0-amd64-kde.iso) (Plasma 5.27.5, KF5 5.103.0, Qt 5.15.8),   
- on another computer using Kubuntu 23.04 (Plasma 5.27.4, KF5 5.104.0, Qt 5.15.8).
Comment 7 Ganton 2024-01-23 03:20:05 UTC
Closing this bug report as I've tried the latest git version (6.0.80) of Plasma and using the numeric keypad: Meta+PageUp and Meta+PageDown work there. Thanks.