FvwmRearrange -auto_tile

The -auto_tile works fine and with -gap it looks nice.
FvwmRearrange -auto_tile -gap_x 6, -gap_y 6

Screenshot click
auto-tile-thumb

After tiling, how to restore the tiling of all windows? With the old options (1.1.0), this does it:

All (CurrentPage, !Iconic, CirculateHit, !Sticky) Maximize Off
WindowId $0 WarpToWindow 50 50

Check this topic.

It doesn’t restore tiled windows after -auto_tile. Or something is missing?

If you pass -maximize option to FvwmRearrange, this will then allow you to target those windows in that state, and toggle maximisation. If you wanted to mark those windows which were tiled as a result of calling FvwmRearrange, you could also add the State style to them, and also use that in your condition:

All (State 1, Maxmimized) Maximize

Thanks. I got the tiled windows restored.

Tile:
FvwmRearrange -auto_tile -gap_x 6, -gap_y 6 -maximize

Restore all windows:
All (CurrentPage, !Iconic, CirculateHit, !Sticky) Maximize Off

1 Like

Your syntax is also wrong remove the comma and just use -gap 6 instead.

Also follow Thomas advice, and only run that command maximized windows.

Doesn’t restore tiled windows.

Read the manual page, pay attention to what all the different conditions do.

Note, you have to add the State 1 style to windows as well to use the suggested command. Without adding that style, the suggested command won’t match any windows. I was mostly just suggesting using Maximized as part of the list you were using (assuming you have a particular reason for that chain of conditionals over just guessing until you get something that works, State 1 style would simplify things a lot.

Maybe we should add a -state n option to FvwmRearrange so that the given number is applied to all affected windows of FvwmRearrange. That way the user wouldn’t have to create a function to call FvwmRearrange and then mark the windows afterwards.

That is doable. Though brings up a few questions, primary how should the state be removed. Should the user then have to add removing the state from the windows (if so writing custom functions might just be best for this). Or should FvwmRearrange be more aggressive and remove the state from all other windows so only the last arranged windows are in the given state?

Some feedback suggests that if FvwmRearrange tiles all current windows, there should also be an option to detile them all at once.

Yes, I think we just allow for a -state n option, and if the chosen state happens to clobber a state which is already in use, sobeit. I class that as the users’ problem.

Well, FvwmRearrange as a module isn’t persistent, and therefore has no knowledge about the state of windows between runs; if anything, -maximize is a handy means of ensuring the window returns to its previous state, only because that’s now Maximise works. In these other instances we’re referring to though, -maximize as an option to FvwmRearrange isn’t enough, so something like -state n might help.

FvwmRearrange -maximize tiles all windows, but doesn’t return all windows at once. It allows one by one.
To detile all, with my limited dev mind, does it need to know about the state of windows? If not tiled, nothing happens. Same as -maximize when tiled. Nothing happens if entered the command a second time, windows stay tiled.

No – as I said before, -maximize is being used as a cheat – to be able to restore windows to their previous size/position.

I don’t think you’re understand what I mentioned in my previous post; FvwmRearrange doesn’t remember state from one run to the next; it’s not persistent. Therefore, the state of the windows is the only thing we have to go on.

I’m sorry you might not be understanding this, but I also don’t have a lot of time to repeat myself ad infinitum either.

For now, we will add a -state n option to FvwmRearrange to help more advanced scripting capabilities, and be done with it. Even then, this option is a pretty shitty one but it’s the best we’ve got.

Thanks, now it’s clear. I will wait for an update.

FvwmRearrange: Add -win_cmd COMMAND option

The new FvwmRearrange update, does it detile all windows? I cannot find info about the -win_cmd option.

Read the manual page, it explains the option.

Please give me the link. I am searching -win_cmd on these pages, but no info.
Man/FvwmRearrange/
Wiki/Modules/FvwmRearrange/

Fvwm3 manpage, no info.

I’ve only very recently merged into git.

It’s not in a release, and therefore not on the website.