On Thu, Jul 09, 2009 at 06:17:33PM -0700, Jason Weber wrote: > On Wed, Jul 8, 2009 at 11:00 PM, Kathryn > Andersen<[email protected]> wrote: > > What I would need, as far as I can see, would be ways to script the > > following: > > - create a new group, dynamically > > - find out what groups are on the current page > > - add a window, by window-id, to a group > > - remove a window, by window-id, from a group > > > > If I could do that, then I could use a combination of FvwmProxy and > > FvwmRearrange to do tabbed tiling for me. ? For example, for a 2-column > > layout: > > > > If one window > > ? ? ? ?maximize > > If two windows > > ? ? ? ?FvwmRearrange (two columns) > > If three windows > > ? ? ? ?FvwmProxy (Group Window #3 with Window #1) > > ? ? ? ?FvwmProxy (Isolate Window #1's group) > > ? ? ? ?FvwmRearrange (two columns) > > > > And so on. > > > > But right now, it looks like I can't do that. > > > > Kathryn Andersen > > So you need more than the semi-static group definitions in the rc. Yep. > I'm not familiar with the scripting tools, Perl I guess in this context, > but I might presume it passes around the same sort of fvwm > clauses that we see in a config files or that fvwm passes to and > from the modules. Yes, anything that can be done in config files or "SendToModule" commands would be fine. > So do we just need some more commands on FvwmProxy? Yes.
> Someone might have to help me out with the syntax. > > SendToModule FvwmProxy Join <group#> > > like sort of what the color buttons do internally. I think SendToModule > gets a window context to know what to act on. It depends, but even if there isn't a window context, and I know the window's id, then I can use the WindowId (window-id) command to give a window context, so it's all good. > I believe 'group 0' is no grouping. Okay. > The named proxy "Group"s that show up in the rc are different from just > being grouped. The naming setups in the rc file are used to do > auto-grouping, but internally, grouped windows just happen to > have an identical group index. (nods) Yes, the rc-configured groups do more than simple grouping. > The same index may be used on different pages since groups > don't span multiple pages. Which is fine, because layouts don't span multiple pages either. > When groups are moved to another page, > it finds a free index there (note how the group's color might change). (nods) > If these numbers get too confusing, perhaps we need an abstraction. > > SendToModule FvwmProxy Tag <tagstring> > > again, on a window context and, indirectly, targeting its group index. > I'm not sure how return values work with scripting, > but somehow we would also need a 'get tag' on a window context. > Then you could also have > > SendToModule FvwmProxy Join <tagstring> Tags would be "names" for groups, is that what you're getting at? I think, whether we have group-numbers or tags, one would need to be able to "get group" or "get tag" on a window context, to find out what group a window is in, or whether it isn't in any group. I don't think the numbers are confusing, so long as one can find them out. To find out what groups are on a given page, and what windows are in those groups. To be able to add and remove windows from those groups. (And if one could add and remove windows, then one could move a window from one group to another, which would be nifty). So, things along the line of: SendToModule FvwmProxy Join <group#> SendToModule FvwmProxy Leave <group#> And possibly SendToModule FvwmProxy Isolate On SendToModule FvwmProxy Isolate Off which would be along the same lines as what one can do with Iconify and Maximize with standard Fvwm, and would give a finer-grained control of Isolation. I'd also need ways of getting back information, which I'm not sure how to do with modules. - the groups on a page (the groups which are "active") - the windows in a group (on this page) - the group of a window (which would presumably be zero if it wasn't in a group) > I would wonder, if a tagged group is split up with the gui, > who keeps the tag? I presume they have to be unique. I'm not sure how that would be done. But as I said above, I think we could probably manage without having to name the groups. Thanks! Kathryn Andersen -- _--_|\ | Kathryn Andersen <http://www.katspace.com> / \ | \_.--.*/ | GenFicCrit mailing list <http://www.katspace.com/gen_fic_crit/> v | ------------| Melbourne -> Victoria -> Australia -> Southern Hemisphere Maranatha! | -> Earth -> Sol -> Milky Way Galaxy -> Universe
