Bug 391728 - Improve ultrawide screen support: Maximize on the left or right area
Summary: Improve ultrawide screen support: Maximize on the left or right area
Status: RESOLVED INTENTIONAL
Alias: None
Product: kwin
Classification: Plasma
Component: scripting (show other bugs)
Version: unspecified
Platform: unspecified Linux
: NOR wishlist
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-03-11 19:50 UTC by Lionel Chauvin
Modified: 2018-03-12 19:48 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
a kwin script that change the "maximize" icon behavior (10.00 KB, application/x-tar)
2018-03-11 19:50 UTC, Lionel Chauvin
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Lionel Chauvin 2018-03-11 19:50:04 UTC
Created attachment 111325 [details]
a kwin script that change the "maximize" icon behavior

More and more 21/9 widescreen displays hit the market and in my opinion this screen format is really convenient. A 21/9 screen  has more or less the same surface as two 4/3 screens put side by side. It is really convenient when you want to view two documents at the same time. This format also allows to have really large windows like a video player in cinema format.

Today, when you click on the "maximize" icon, it places the window on the whole work area. It is also possible to drag and drop a window on the edge of the screen so that it takes half of it. In my opinion this feature is not very convenient to use.

I propose a modification of the behavior of the "maximize" icon so that it chooses automatically the best zone according to the position: the left side, the right side or the full work area.

To illustrate the behavior I want to achieve I made a video:
https://youtu.be/R7kNSL68zYY

I wrote a KWin script that gets this behavior. You can find it as an attachment and I invite you to test it. It should work on a 16/9 screen too.

I do not think the scripting system can allow to properly implement this feature. I am experiencing the following issues:
- There are no shadows when a window is maximized.
- There is no animation when maximizing on one side of the screen

The first problem is due to a choice of KWin to hide shadows that are not usually needed when a window is maximized. It should be possible to tell him that we want to display a shadow on the edge that is still visible.

The second problem is due to the fact that "clientMaximizeSet" signal is already emitted when the script changes the window geometry. The "maximize" animation is then cut off.

I'm waiting for your comment about this idea and I hope this feature can be implemented directly in KWin or that the scripting system will be improved to make it possible.
Comment 1 Martin Flöser 2018-03-11 20:49:28 UTC
We cannot change the maximize button without breaking lots of internal and external state. Furthermore what you suggest is anything but not maximize. This would be highly confusing to the userbase. A UI needs to function in an expected way. If a maximize button does random things ( I'm exaggerating on purpose) our users cannot trust the UI any more and in worst case move somewhere else.

What you seem to wish for is better exposing of quick tiling. As given your description what you want is quick tile left/right. This again is a reason to not change the maximize button as the functionality already exists in other areas.
Comment 2 Nate Graham 2018-03-11 21:22:34 UTC
Right, this is definitely a better case not for changing the Maximize button behavior, but rather for making Quick Tiling more discoverable. Most other platforms have the functionality bound to Meta+Left/Right, but we don't, I notice.
Comment 3 Lionel Chauvin 2018-03-11 21:40:39 UTC
Ok, I understand.
So, what is missing is the ability to add as many icon as needed in the window decoration in order to properly command the quick tiling.
And the quick tiling must manage several states in order to restore a window to its previous position.
This will not break more stuff ?
Comment 4 Martin Flöser 2018-03-12 05:11:29 UTC
I'm not saying we should add a deco button for it. But it could be added to the user action's menu.
Comment 5 Lionel Chauvin 2018-03-12 19:48:32 UTC
I am not against add an action in the user's menu. It could help to discover the shortcut but I don't see how it can help to discover the drag'n drop to the screen edge.

I already known the existence of Quick Tiling. The drag'n drop is not the way I would like to interact with my windows. My previous setting had two screens and I will not be the only one that migrate to an ultrawide screen and to expect the maxmimize icon to be smarter. So I will continue to use my kwin script, even if it is a big hack.

Is there a way to trigger an animation from a kwin script ?