Bug 464513 - Some Panel popups inappropriately centered with small non-maximized panel
Summary: Some Panel popups inappropriately centered with small non-maximized panel
Status: RESOLVED FIXED
Alias: None
Product: libplasma
Classification: Frameworks and Libraries
Component: libplasma (show other bugs)
Version: 5.102.0
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords: regression
Depends on:
Blocks:
 
Reported: 2023-01-19 17:24 UTC by musicatomasperez
Modified: 2023-01-31 20:45 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In: 5.103
Sentry Crash Report:


Attachments
misaligned menu (492.00 KB, image/png)
2023-01-19 17:24 UTC, musicatomasperez
Details

Note You need to log in before you can comment on or make changes to this bug.
Description musicatomasperez 2023-01-19 17:24:07 UTC
Created attachment 155433 [details]
misaligned menu

SUMMARY
***
if the default KDE panel is centered, when opening a menu from the taskbar (for example volume control, networking, or the calendar) the menu appears on the center of the screen instead of above the icon that was pressed. this appears to happen only when the panel is centered (see: https://pomf2.lain.la/f/4ghd3g24.png) , aligning the panel to either the left of the right makes the popup menu behave properly https://pomf2.lain.la/f/eld56cg0.png
***


STEPS TO REPRODUCE
1.  align the panel to be on the center of the screen
2. click on either the volume control icon, networking icon or calendar


OBSERVED RESULT
1. the menu isn't lined up properly.

EXPECTED RESULT


Operating System: Arch Linux
KDE Plasma Version: 5.26.5
KDE Frameworks Version: 5.102.0
Qt Version: 5.15.8
Kernel Version: 6.1.6-arch1-3 (64-bit)
Graphics Platform: X11
Comment 1 Nate Graham 2023-01-23 21:45:01 UTC
Looks like another edge case, like Bug 462930.
Comment 2 Bug Janitor Service 2023-01-26 16:44:56 UTC
A possibly relevant merge request was started @ https://invent.kde.org/frameworks/plasma-framework/-/merge_requests/689
Comment 3 Nate Graham 2023-01-31 20:25:18 UTC
Git commit eda6caabcffff484544af8949d0ca0a3ea3ce333 by Nate Graham, on behalf of Niccolò Venerandi.
Committed on 31/01/2023 at 20:25.
Pushed by ngraham into branch 'master'.

Dialog: Fix calculation of distance between dialog and parent applet

`ParentRect` is not using the same coordinate system as `dialogPos` and `avail`,
which could result in incorrect placement of dialogs when you have e.g. multiple
monitors or a non-maximized panel. This replaces `ParentRect` with `dialogPos` so
the coordinate systems remain in sync.
Related: bug 464201
FIXED-IN: 5.103

M  +2    -2    src/plasmaquick/dialog.cpp

https://invent.kde.org/frameworks/plasma-framework/commit/eda6caabcffff484544af8949d0ca0a3ea3ce333
Comment 4 Nate Graham 2023-01-31 20:45:59 UTC
Git commit 1e0042c750756d0963d11d125978f47ea830d495 by Nate Graham, on behalf of Niccolò Venerandi.
Committed on 31/01/2023 at 20:45.
Pushed by ngraham into branch 'cherry-pick-eda6caab'.

Dialog: Fix calculation of distance between dialog and parent applet

`ParentRect` is not using the same coordinate system as `dialogPos` and `avail`,
which could result in incorrect placement of dialogs when you have e.g. multiple
monitors or a non-maximized panel. This replaces `ParentRect` with `dialogPos` so
the coordinate systems remain in sync.
Related: bug 464201
FIXED-IN: 5.103


(cherry picked from commit eda6caabcffff484544af8949d0ca0a3ea3ce333)

M  +2    -2    src/plasmaquick/dialog.cpp

https://invent.kde.org/frameworks/plasma-framework/commit/1e0042c750756d0963d11d125978f47ea830d495