When I open an xterm with ‘Exec exec xterm’ and I check the FvwmIdent info, it lists the window size of 322 (I’m assuming pixels). But when I run ‘+ I PipeRead “echo $[w.height]” > opp’ it says the height is 356.
That is correct, fvwm keeps track of both the window’s geometry and the frame’s geometry (the window + borders/titlebar). In this case FvwmIdent is reporting the window’s geometry while $[w.width] and $[w.height] are reporting the frame’s geometry, which is why it is bigger. If you want the same output as FvwmIdent use $[cw.width] and $[cw.height] for the client window (or the geometry without the frame).
I Current ResizeMove keep $[w.height]+$[w.y]p keep 0
But when the window is already at the top of the screen, the bottom grows by 14, when it shouldn’t grow at all. I’m not sure what is going on.
I’m trying to use the handles/borders to expand a window to the edge of the screen, only in the direction that is clicked. If anybody can help shed some light on what I am clearly missing, it would be appreciated.
Really it sounds like you need to use Maximize with the grow options. Here is what I use to grow my window in a specified direction using key bindings. This also makes it so I can keep growing beyond hitting the first window.
DestroyFunc Grow
AddToFunc Grow
+ I Maximize keepgrowing True $0 $1
Key Up WTSF CSM Grow 0 growup
Key Down WTSF CSM Grow 0 growdown
Key Right WTSF CSM Grow growright 0
Key Left WTSF CSM Grow growleft 0
Okay, then Maximize with grow options is what you want. Note the True puts the window in a maximized state so maximize can restore its original size if you want. If you don’t want this, read the manual page for other details.
Anyways, since you want this to grow to the edge of the screen and ignore other windows, just grow on a Layer that no other windows are on, by default no windows will be on Layer 7 or higher. So something like this should work for the Grow function mentioned above.
You should read the manual page for details, it is quite useful. The growonlayers only states what layers to consider other windows when growing, it doesn’t change the layer the window is on. I just used this as a way to ignore all other windows and always grow to the edge of the screen.
There are a few issues I see, first it appears that Resize doesn’t accept + as an argument (read up on what arguments Resize actually takes), so you’ll nave to do the addition before sending it to the ResizeMove command. Using the new $[math] expansion (only in fvwm3 version 1.1.1 and newer) allows the following (for older versions of fvwm, you’ll have to do the math in a shell combined with PipeRead):
Excellent to know about the $[math], I’ll have to wait for that.
I do remember now that I ignored the ‘grow’ commands section, because I assumed it would be the same results of the Resize ‘direction’ options that make it manually adjustable.