Re: Preserved Window Placement



Thanks everybody for your thoughtful input!

On Wed, Oct 24, 2012 at 1:27 PM, Federico Mena Quintero
<federico gnome org> wrote:
> Not every application has a single, uniquely-identifiable window.  That
> is, applications have multiple, ambiguously-identified windows.

What if the window manager's API (pardon my lack of proper
terminology) gave applications tools for identifying a primary window?
For that matter, giving them a way to identify all of their windows.

Here's some info about OSX’s NSWindowController:
https://developer.apple.com/library/mac/#documentation/Cocoa/Reference/ApplicationKit/Classes/NSWindowController_Class/Reference/Reference.html

NOT THAT WE WANT TO MIMIC OSX. But it is a good example. Thinking
about preserved window placement never even came to mind until I
started using Linux, where it basically doesn't exist. In the history
of Mac OS it worked consistently enough that I took it for granted. No
point in recreating the wheel.

> Then, the "only" problems from the application's point of view is
> saving/restoring those geometries at the right time,

Well, a good place to start would be to save the geometries...

- When the window is created
- Every time the window's dimensions or position are altered

> saving the (hopefully opaque) strings in the right place,

Isn't the operating system already doing tasks like this all the time?

> garbage-collecting old
> settings, doing something useful when the expected monitor size is
> different from the current monitor size,

If we could get preserved window placement working, making an informed
decision about how to adapt/not adapt to a change in display size
would be relatively easy. We need to focus on the most frequently
encountered situation first.

> doing something reasonable when
> you have two instances of the same application...

Yes. That's what it needs to do. See the NSWindowController page above.

It seems like, rather than try to make a decision about how this
should work, Linux desktops have collectively decided to “do
essentially nothing and let individual applications figure it out”
instead.

And the idea that the window manager shouldn't do this and that the
applications themselves should do it will only produce one result: a
complete mess of inconsistent behavior that will leave the user to
surmise that window placement across the system is arbitrary, random
or maybe just broken. Which is exactly our current situation.

A solution like Devil’s Pie is nice (thank you!), but it's solving the
problem from the wrong end. Rather than having a policy for
applications to identify their windows and their positions and
expected behavior in a standard fashion, Devil’s Pie tries to identify
unlabeled, unorganized windows by the use of filters (tell me if I'm
wrong) and then dictate size and position.

In my personal experience that sounds a lot like the frustrating act
of trying to separate some specific black angus cows from a large herd
of almost identical black angus cattle with the added unrealistic
gotcha of none of the cattle having ear tags.

Is there any possibility of reconsidering this problem as something
that should be managed by the window manager?

Thanks for listening.

Jason Simanek


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]