Bug 314388 - position / size rules should support percentage measure
Summary: position / size rules should support percentage measure
Status: REPORTED
Alias: None
Product: kwin
Classification: Plasma
Component: rules (show other bugs)
Version: 4.9.5
Platform: Arch Linux Linux
: NOR wishlist
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-02-03 23:09 UTC by Martín Cigorraga
Modified: 2022-04-08 19:28 UTC (History)
1 user (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 Martín Cigorraga 2013-02-03 23:09:12 UTC
As @Thomas Lübking suggested I'm filing a new bug for this issue, I originally added this description in this bug: https://bugs.kde.org/show_bug.cgi?id=161325

--

I'm not sure about how easy to implement is this but I agree that this is a much needed feature.
For example, my laptop's screen size is 17,1" / 1600x900 while my home monitor screen size is 23" / 1920x1080 so the rules I made for windows positioning in my laptop aren't honored when I use the bigger monitor.
Take a look of these screenshots pairs, first row sports the 1600x900 screenshots while the second row sports the 1920x1080 screenshots:

http://i.imgur.com/PWgDnXX.jpg  vs.  http://i.imgur.com/RpDuXL1.jpg
http://i.imgur.com/zwC63sE.png  vs.  http://i.imgur.com/Xke7yhO.jpg
http://i.imgur.com/J75wOM6.png  vs.  http://i.imgur.com/e4olwwz.jpg
http://i.imgur.com/ynGZONn.jpg  vs.  http://i.imgur.com/q48mt6k.jpg
http://i.imgur.com/CDn0L2O.png  vs.  http://i.imgur.com/DjtuXBh.png

Seems we need to stop using the absolute (x0,y0) coordinates as a point of reference.
As Thomas explains, the actual window positioning "points resolution dependent rules (or percentual geometry ruling)".

Reproducible: Always

Steps to Reproduce:
1. Change the screen resolution or attach an external monitor with a bigger resolution.
2.
3.
Actual Results:  
Windows will honor their positions settings on the bigger resolution screen thus breaking the original layout.

Expected Results:  
The pretendend windows layout should be honored.

May be one way to workaround this problem is by adding an option to make each window positioning *relative* to something else, for example a panel, so this way when the user sets the windows positions he/she can make sure windows will be placed in the right place no matter what resolution have the screen at any given time.
Comment 1 Thomas Lübking 2013-07-17 12:48:01 UTC
For clarification: are you more interested in a percentual positioning (25% of x and 16% of y) or a gravity one (5px from west and 20px from south)?

Latter is (now) bug #320908