-
Notifications
You must be signed in to change notification settings - Fork 107
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Overhaul of workspace code #194
Conversation
Always using a |
I don't see internal discussion about this, so just wanted to confirm, has @pop-os/ux approved this design decision?
The only use case for displaying a window on multiple displays that I've personally used in the past (that was an actual reason it needed to be done, rather than just being nice to see on both) was resizing a video editor to span both just to take a larger screenshot of the timeline. However, I can also imagine this might impact some video games, and probably other situation-specific use cases. I'd expect we'd be okay with not having this feature at launch, but it's probably a limitation we're going to want to move past eventually. |
Limiting windows to only be on one display at a time was a design decision. We couldn't find a lot of cases that warranted a very complicated code to enable people to have a window span both displays. I can imagine those pretty rare and infrequent one off cases when someone would need it but it still seems more of an edge case. |
Yes, this was approved by @maria-komarova and @WatchMkr.
That might be difficult in terms of focus, but regardless the current design isn't the final one. The window is supposed to be slightly transparent on the workspace, it wouldn't be placed, when dragging. I guess that hint alone would make this less jarring?
That is a very good question though, I guess the expected behaviour in that case was never defined.
Video games mostly create a window per output, if they support multi-monitor setups. Something like nVidia Surround / AMD Eyefinity needs deeper integration to synchronize outputs anyway.
In that case this refactoring would not have happened. As to support the feature I basically have to revert 80% of this PR again, most of the code was already there and was causing problems frequently. If this is going to be re-introduced, either that will happen much later or this PR should be dropped. But I honestly see us rather supporting specific use-cases (e.g. maximizing/fullscreen across multiple outputs), than arbitrary overlaps from the previous discussions on this feature. |
I need to look more into it since it was never designed in detail but quick thought is we might want to limit the movement of the cursor to the focused display where the window is resized. |
I do wonder though if the behavior could in some way be better when a window is dragged to overlap two monitors. The part on one window simply ceasing to appear when the drag ends seems sub-optimal. I guess the window suddenly moving at end of drag to fit on one monitor wouldn't be the best experience either. |
I assumed it would work like this, but I do think the current system (even before the transparency is implemented) is slightly more seamless. The problem is that the current way (at least before the transparency) makes it feel like dropping it on multiple displays should be possible. The transparency sounds like it may help. If the decision's already been made that this will not be supported in the foreseeable future, I personally disagree (especially having already encountered at least one of the "rare and infrequent" use-cases myself), but that's fine/acknowledged. I mainly just wanted to have it on the record since it's a big change and difference from other environments. |
This does appear to fix #161 |
The window behavior is very strange. Moving a floating window across displays works while dragging but when dragging stops only the part on the display with the majority of the window shows. While I don't specifically size windows across multiple displays I don't think we can reasonably discard parts of a window that are on different displays. |
I'm still seeing issues with X11 games hanging on a black screen. In general, it seems intensive X11 programs can slow down all X11 programs running. |
#177 is still present. Occurs with single and multi-display setups. Tested with Google Chrome menus that normally move to the left of the original menu if they'd go off-screen. |
#178 is still present. |
#181 may be fixed; however, floating windows won't stay resized when they're moved (resize window, move via header) so can't tell for certain. |
New Issue: Multi-display changing display position bug
EDIT: logged out and back in and this went away. |
New issue: maximized windows show the accent but shouldn't |
I think gaming would take a hit from this for at least a couple niche users myself included. most games are at least somewhat responsive to arbitrary resolutions now. This means if the game can see it as a supported resolution, it can output it. one of the setups I have done in that past. that I am looking forwards to is using gamescope to play games with arbitrary resolutions that span across some, but not all monitors. one of the setups I have used is [ 1920x1080 ], [ 3840x2160 ], [ 2560x1080 ] with a monitor on top. not super conventional, but my system is primarily for work, and that is what worked out for me. when you do a 2x integer scale on 4k it works out quite nicely. this is really easy to setup on windows, and even easier on linux thanks to gamescope
this can then nicely span the three displays, as if it was 3x 16:9 screens, leaving part of the ultrawide availible for discord or whatever other things the user may need. I realize this is for sure an edge case, but it works fine, I'm not the most perceptive to desync across monitors, but I haven't really noticed much on kwin or sway. |
Spanning multiple outputs for fullscreen application is a known use-case (as mentioned above), that will be supported at some point. But that alone doesn't warrant arbitrary overlaps, which have a bunch of additional challenges and problems. Even partially overlapping fullscreen windows like you are describing, are easier to support on their own. |
A crash I saw running this branch:
|
So this happened trying to move a window. And since the both There is code in place to first unmaximize the window in this case, but potentially this isn't catching the state correctly at the same frame, so I added this commit as a potential fix for good measure: b205a54 Though I don't believe this is the cause, probably a more convoluted interaction caused this state mismatch. Though without steps to reproduce this will be difficult to track down. |
cb1381b
to
4b0368e
Compare
4642a08
to
ebe61e3
Compare
Fixes lagging tab animations by discarding the expired animations.
refactor: only apply updates if there is a change in the theme refactor: include theme in state cleanup: theme integration
a6de6b6
to
1d799f4
Compare
This is a large refactor of handling of workspaces and their properties.
Most importantly this gets rid of layouts spanning multiple outputs in global-workspace mode, causing every internal logical workspace to only have one assigned output. This means windows spanning multiple outputs aren't possible any more by design, but simplifies a lot of the shell/workspace code.
Additionally this introduces two new typed Coordinate-spaces
Local
andGlobal
, which referr toLogical
coordinates, that are either Output/Workspace-local (which is now the same thing, we previously effectively had three spaces without any typing) or in global coordinates. This should fix a couple of X11 bugs regarding multiple outputs and frozen rendering / misplaced popups / broken input.Lastly this PR changes the maximize/fullscreen logic once again. Instead of treating maximized as a special fullscreen-like state, maximized windows now temporarily belong to the floating layer, resulting in much more tranditional maximized behaviour. The fullscreen code is thus now separated and ditches the
CosmicWindow
-wrapper again, which gets rid of window decorations for fullscreen windows (as it should be).Point of this PR is to enable testing. It is still not done. Remaining TODOs:
Shell::set_mode
xdg_shell::set_fullscreen
output hint properlyShould address:
Global
workspaces mode #93