Bug 437578 - Context menu appear in wrong position when there is a secondary monitor on top or left
Summary: Context menu appear in wrong position when there is a secondary monitor on to...
Status: RESOLVED DUPLICATE of bug 440364
Alias: None
Product: plasmashell
Classification: Plasma
Component: generic-multiscreen (show other bugs)
Version: 5.21.5
Platform: Manjaro Linux
: NOR normal
Target Milestone: 1.0
Assignee: Aleix Pol
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-05-23 22:03 UTC by Hamid Reza Arzaghi
Modified: 2021-08-16 22:41 UTC (History)
8 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
picture1 (686.13 KB, image/jpeg)
2021-06-07 18:51 UTC, Ajeje
Details
picture2 (673.09 KB, image/jpeg)
2021-06-07 18:51 UTC, Ajeje
Details
screenshot (863.81 KB, image/jpeg)
2021-06-13 13:01 UTC, Mathias Homann
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Hamid Reza Arzaghi 2021-05-23 22:03:32 UTC
SUMMARY
I always use a secondary monitor attached to my laptop. The secondary monitor is above the primary screen. When I right-click on a file or folder on the primary screen desktop, the context menu appears on the secondary monitor!

STEPS TO REPRODUCE
1. Connect a secondary monitor and place it on top or left of the primary screen.
2. Right-click on a folder/file on the primary desktop.

OBSERVED RESULT
The context menu will appear on the secondary monitor!

EXPECTED RESULT
The context menu should appear in the right place near the selected folder/file.

SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: KDE neon User Edition 5.21 x86_64 
(available in About System)
KDE Plasma Version: 5.21.5
KDE Frameworks Version: 5.82.0
Qt Version: 5.15.2

ADDITIONAL INFORMATION
Comment 1 David Edmundson 2021-05-23 22:57:09 UTC
X or wayland?
What app(s) is this happening in?
Comment 2 Hamid Reza Arzaghi 2021-05-24 08:06:41 UTC
(In reply to David Edmundson from comment #1)
> X or wayland?
> What app(s) is this happening in?

I use X11.
I mean the bug happens when I right-click on any file or folder on the main desktop.
Comment 3 Ajeje 2021-06-07 18:51:03 UTC
Created attachment 139086 [details]
picture1
Comment 4 Ajeje 2021-06-07 18:51:19 UTC
Created attachment 139087 [details]
picture2
Comment 5 Ajeje 2021-06-07 18:53:30 UTC
I have the same issue, I've attached 2 pictures: context menu is opened half a monitor too on the left if I click on my main monitor but ONLY for desktop icons.
Also I can't really control where programs will open: ex that root password prompt I have at boot for radeonprofile.

Some system infos:
Operating System: Manjaro Linux
KDE Plasma Version: 5.21.5
KDE Frameworks Version: 5.82.0
Qt Version: 5.15.2
Kernel Version: 5.12.8-1-MANJARO
OS Type: 64-bit
Graphics Platform: X11
Processors: 12 × AMD Ryzen 5 1600 Six-Core Processor
Memory: 15.6 GiB of RAM
Graphics Processor: Radeon RX 580 Series 

This is my xrandr output (minus the unused resolutions)
`
Screen 0: minimum 320 x 200, current 3000 x 1920, maximum 16384 x 16384
DisplayPort-0 connected primary 1920x1080+1080+420 (normal left inverted right x axis y axis) 598mm x 336mm
1920x1080 60.00 + 74.97* 50.00 59.94

DisplayPort-1 disconnected (normal left inverted right x axis y axis)
DisplayPort-2 disconnected (normal left inverted right x axis y axis)
HDMI-A-0 connected 1080x1920+0+0 right (normal left inverted right x axis y axis) 598mm x 336mm
1920x1080 60.00 + 74.97* 50.00 59.94

DVI-D-0 disconnected (normal left inverted right x axis y axis)
Comment 6 Ajeje 2021-06-07 18:56:12 UTC
Forgot to mention: if I rearrange my monitors so the vertical one is on the right the issue goes away.
Bios menu is displayed correctly on my main monitor (central, horizontal, dp)
Comment 7 Mathias Homann 2021-06-13 13:01:47 UTC
Created attachment 139284 [details]
screenshot
Comment 8 Mathias Homann 2021-06-13 13:02:47 UTC
same here: primary is on the right, secondary is on the left - right-clicking an icon on the right screen pops open the context menu on the left screen.

Operating System: openSUSE Tumbleweed 20210611
KDE Plasma Version: 5.22.0
KDE Frameworks Version: 5.82.0
Qt Version: 5.15.2
Kernel Version: 5.12.9-1-default (64-bit)
Graphics Platform: X11
Processors: 8 × Intel® Core™ i7-4771 CPU @ 3.50GHz
Memory: 31.3 GiB of RAM
Graphics Processor: GeForce GTX 1050/PCIe/SSE2
Comment 9 Avery KDEBug 2021-07-07 00:48:18 UTC
I am experiencing the same issue. I've got my primary monitor on the right and the secondary on the left.

Operating System: Arch Linux
KDE Plasma Version: 5.22.2
KDE Frameworks Version: 5.83.0
Qt Version: 5.15.2
Kernel Version: 5.10.47-1-lts (64 bit)
Graphics Platform: X11
Processors: 4 × Intel® Core™ i5-4690k CPU @ 3.50GHz
Memory: 15.6 GiB of RAM
Graphics Processor: GeForce GTX 970/PCIe/SSE2

xrandr output:
DVI-I-1 connected primary 1920x1080+1920+0 (normal left inverted right x axis y axis) 531mm x 298mm
HDMI-0 connected 1920x1080+0+244 (normal left inverted right x axis y axis) 480mm x 270mm
Comment 10 Ajeje 2021-07-13 18:34:47 UTC
(In reply to Ajeje from comment #5)
> I have the same issue, I've attached 2 pictures: context menu is opened half
> a monitor too on the left if I click on my main monitor but ONLY for desktop
> icons.
> Also I can't really control where programs will open: ex that root password
> prompt I have at boot for radeonprofile.
> 
> Some system infos:
> Operating System: Manjaro Linux
> KDE Plasma Version: 5.21.5
> KDE Frameworks Version: 5.82.0
> Qt Version: 5.15.2
> Kernel Version: 5.12.8-1-MANJARO
> OS Type: 64-bit
> Graphics Platform: X11
> Processors: 12 × AMD Ryzen 5 1600 Six-Core Processor
> Memory: 15.6 GiB of RAM
> Graphics Processor: Radeon RX 580 Series 
> 
> This is my xrandr output (minus the unused resolutions)
> `
> Screen 0: minimum 320 x 200, current 3000 x 1920, maximum 16384 x 16384
> DisplayPort-0 connected primary 1920x1080+1080+420 (normal left inverted
> right x axis y axis) 598mm x 336mm
> 1920x1080 60.00 + 74.97* 50.00 59.94
> 
> DisplayPort-1 disconnected (normal left inverted right x axis y axis)
> DisplayPort-2 disconnected (normal left inverted right x axis y axis)
> HDMI-A-0 connected 1080x1920+0+0 right (normal left inverted right x axis y
> axis) 598mm x 336mm
> 1920x1080 60.00 + 74.97* 50.00 59.94
> 
> DVI-D-0 disconnected (normal left inverted right x axis y axis)

There was a big update in manjaro today, kde got updated, issue persists, I don't know if this helps.

Operating System: Manjaro Linux
KDE Plasma Version: 5.22.3
KDE Frameworks Version: 5.84.0
Qt Version: 5.15.2
Kernel Version: 5.13.1-3-MANJARO (64-bit)
Graphics Platform: X11
Comment 11 heroofgraz 2021-08-03 19:04:04 UTC
I have the same issue. Primary monitor is on the right, secondary on left. Context menu appears on the secondary monitor. Furthermore, if I move the secondary monitor to the right and then right-click a desktop icon on the secondary monitor, it erroneously appears on the primary monitor. So it doesn't seem to be an issue of which monitor is primary/secondary, but rather which one is on the left/right.

I would guess it's an issue where it's not properly transforming the coordinates inside the monitor to the global coordinates of the dual monitor setup. I.e. if I try to open a context menu at coordinates (0,0) on the right monitor, it doesn't account for the fact that this point is actually (1366,0) in the global space of the two monitors. And so it just opens at the global (0,0), which will be on the leftmost monitor.

Operating System: Arch Linux
KDE Plasma Version: 5.22.4
KDE Frameworks Version: 5.84.0
Qt Version: 5.15.2
Kernel Version: 5.13.7-arch1-1 x86_64
Graphics Platform: X11
Comment 12 Nate Graham 2021-08-16 22:41:57 UTC

*** This bug has been marked as a duplicate of bug 440364 ***