Bug 458667

Summary: Plasmashell gets confused about displays in a 3 display setup when one display is disconnected/reconnected/changed online
Product: [Plasma] plasmashell Reporter: dinumarina
Component: generic-multiscreenAssignee: Plasma Bugs List <plasma-bugs>
Status: RESOLVED DUPLICATE    
Severity: normal CC: aleixpol, dinumarina, nate, notmart
Priority: NOR    
Version: 5.25.4   
Target Milestone: 1.0   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description dinumarina 2022-09-03 18:16:23 UTC
I have a 3-monitor setup around my laptop:
1) Native laptop display
2) Displayport display, usually connected and turned on
3) HDMI port is connected to a HDMI switch which can route it to a HDMI projector, external soundsystem, etc. HDMI IDs supplied by the HDMI switch can vary (from disconnected to various display ids)
***


STEPS TO REPRODUCE
1. Multi-display setup (I use 3)
2. Disconnect and reconnect display(s) online (no restart); switch one display with a different ID display; flip the notebook lid up and down (to turn off native display). It's just the physical connect and disconnect and state change of the displays, don't touch any settings.

OBSERVED RESULT

Any of the above operations will result, not always but at random times, in some of these consequences:
- Displays IDs switched (Display 1 listed as Display 2 and vice-versa, physical characteristics flipped). Probably upstream.
- Display IDs duplicated (Display 1, Display 1). Probably upstream.
- Toolbars swapped between displays, even when the final configuration is identical to the initial configuration. The toolbar "dance" gets persisted: even if immediately restarting computer, primary display toolbars remain moved on secondary or vice-versa
- Toolbars wrongly sized on displays
- Primary display switch not working in settings to change primary display
- Display positions moved around the global rendering coordinates, even when final config is identical to initial
- HDMI display resolution or scaling changed for previously known display (including when final = initial)

Some of these problems seem upstream (cannot be fixed until rebooting the system); duplicate device IDs seems to be one of them.

Others are immediately fixed by plasmashell --replace

EXPECTED RESULT
- Previously known configurations retain the same primary display, as well as per-display resolution, scaling, and global coordinates
- Toolbars are properly positioned
- Toolbars never jump from primary display to a secondary or vice-versa

SOFTWARE/OS VERSIONS
FC36
Plasma 5.25.4 
KDE Frameworks Version: 5.97.0
Qt Version: 5.15.5
Display ports: Intel HD 4600 (possibly relevant for upstream bugs)
Comment 1 dinumarina 2022-09-03 18:20:05 UTC
In the above description, I'm referrring to "panels" as "toolbars". Sorry for the terminology. Panels jump around.
Comment 2 Nate Graham 2022-09-09 00:04:43 UTC
Ultimately all of these issues are caused by the problem described in Bug 450068, which is a focus area and will be fixed soon-ish.

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