Bug 387736 - Last window size restored (correctly) only for most left display
Summary: Last window size restored (correctly) only for most left display
Status: RESOLVED DUPLICATE of bug 427875
Alias: None
Product: frameworks-kconfig
Classification: Frameworks and Libraries
Component: general (show other bugs)
Version: 5.47.0
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: Matthew Dawson
URL: https://bugreports.qt.io/browse/QTBUG...
Keywords:
Depends on:
Blocks:
 
Reported: 2017-12-09 11:41 UTC by hugor.hugolin
Modified: 2021-09-16 17:48 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description hugor.hugolin 2017-12-09 11:41:48 UTC
Inside KWindowConfig::restoreWindowSize
const QRect desk = window->screen()->geometry();
always returns resolution of the most left screen (regardless whether it is primary and regardless of where the window actually appears).

This seems to be the same bug as reported here: https://bugreports.qt.io/browse/QTBUG-50788

This have a nasty effect that when you open kf5 application it always has [a size it had last time when it was closed on most left screen].


Even if it is found out that this is a qt-bug workaround is probably possible, because the virtually same code inside KWindowConfig::saveWindowSize returns correct screen.
Comment 1 hugor.hugolin 2018-07-14 10:37:12 UTC
The bug is also reproducible on Wayland.
Restoring last window size basically works only on the most left screen!

I wonder how can anybody use kf5 applications on any setup where your most used screen is not on the left.
Comment 2 Nate Graham 2018-07-15 03:38:54 UTC
Since you've identified the code responsible, any chance you'd be interested in producing a patch? Here's the documentation:

- https://community.kde.org/Get_Involved/development
- https://community.kde.org/Infrastructure/Phabricator
Comment 3 Nate Graham 2021-09-16 17:48:55 UTC

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