fvwm3 icon indicating copy to clipboard operation
fvwm3 copied to clipboard

Window placement enhancement

Open oredaze opened this issue 2 years ago • 2 comments

I suspect this would be a rather minor thing to implement, but very nice. The idea is that you use a combination of PositionPlacement Center(for the first one) and MinOverlapPlacement (for the rest). Openbox does this and it's the way that makes the most sense to me.

oredaze avatar Aug 15 '21 15:08 oredaze

Hi @oredaze

Is this for one type of window, or all? Either way you should be able to do this with something like:

Style * InitialMapCommand Foo

DestroyFunc Foo
AddToFunc Foo
+ I None ($[w.class]) Move ....
+ I TestRc (NoMatch) Style .... MinOverlapPlacement

ThomasAdam avatar Aug 15 '21 17:08 ThomasAdam

It is for all types of windows. I have tried to make this work based on your example, but I can't. The type of logic that these functions use is kinda confusing to me. It looks to me as if your example tries to Move a window if no window exists, which obviously can't happen, and if a window exists it just goes to the TestRc line...

Also I am not sure if my explanation was clear enough, so let me paraphrase myself just in case: The placement of the very first window in an empty desktop should be centered, the second and following ones should use MinOverlapPlacement.

oredaze avatar Aug 18 '21 07:08 oredaze

This can be done through conditionals and PipeRead -- I don't think this feature needs adding directly to fvwm3.

ThomasAdam avatar May 10 '23 20:05 ThomasAdam