Maximize window but leave space at the top

Problems with decorations or key/mouse bindings? Or perhaps you have a cool mouse/key binding you want to share.
LeoSimon
Cat in the hat
Cat in the hat
Posts: 44
Joined: Mon Jul 07, 2008 5:07 am

Maximize window but leave space at the top

Postby LeoSimon » Sun Oct 31, 2010 2:02 am

Hi, I have my title bar at the top of the screen not the bottom as is standard.
I want to set my F10 to maximize a window but to leave space at the top of the screen so it doesn't cover the title bar.
I.e., I'd like an analog of
Key F10 W A Maximize 100 100 -21p
which leaves space at the bottom. Is there a way to leave it at the top instead?

I imagine that I could do something clever with 'grow' options but the syntax is defeating me. I tried he command
Key F10 W A Maximize growonlayers $[w.layer] -1 grow grow
to see what it would do, but to make it work I think I'd have to know how to make my title bar a lower level than my other windows.

Thanks! Leo

thomasadam
Administrator
Administrator
Posts: 3043
Joined: Mon Nov 08, 2004 1:12 am
Location: England
Contact:

Re: Maximize window but leave space at the top

Postby thomasadam » Sun Oct 31, 2010 12:38 pm

Use FVWM 2.5.X if you're not already, remove your current Maximize implementation, and read about "EwmhBaseStruts".

-- Thomas Adam

LeoSimon
Cat in the hat
Cat in the hat
Posts: 44
Joined: Mon Jul 07, 2008 5:07 am

Re: Maximize window but leave space at the top

Postby LeoSimon » Sun Oct 31, 2010 9:40 pm

Thanks for the quick reply. Spent an hour or two trying to understand how to incorporate EwmhBaseStruts into my configuration, failed dismally. I decided to shift my TaskBar down to the bottom of the screen then suddenly everything became easy, since
Maximize 100 96 left the space I wanted.

thomasadam
Administrator
Administrator
Posts: 3043
Joined: Mon Nov 08, 2004 1:12 am
Location: England
Contact:

Re: Maximize window but leave space at the top

Postby thomasadam » Sun Oct 31, 2010 9:48 pm

LeoSimon wrote:Thanks for the quick reply. Spent an hour or two trying to understand how to incorporate EwmhBaseStruts into my configuration, failed dismally. I decided to shift my TaskBar down to the bottom of the screen then suddenly everything became easy, since
Maximize 100 96 left the space I wanted.


You're still failing. Exactly what is it you're not understanding? For example:

Code: Select all

EWMHBaseStruts 0 0 17 0


Says to leave 17 pixels FROM THE TOP of the screen alone. If I wanted the same on the bottom as well, I'd use this:

Code: Select all

EWMHBaseStruts 0 0 17 17


Guess what the Maximize command does? It respects these hints, hence:

Code: Select all

Maximize


Is then all that's needed for that. No other options.

Stop failing, Leo!

-- Thomas Adam

LeoSimon
Cat in the hat
Cat in the hat
Posts: 44
Joined: Mon Jul 07, 2008 5:07 am

Re: Maximize window but leave space at the top

Postby LeoSimon » Mon Nov 01, 2010 9:21 am

Ok, now i passed. Couldn't believe it was that simple, thought I had to do all sorts of complex things.
It works like a charm!!

Thanks very much for your help, Thomas


Return to “Decorations and bindings”

Who is online

Users browsing this forum: No registered users and 1 guest