On Wed, Mar 05, 2008 at 11:00:49PM -0500, John S. Yates, Jr. wrote:
> I have not looked at the code in a good while but wanted to suggest
> the following code concept.  My thought sprang from Anselm writing
> 
> > I propose using setlayout("[M]") and setlayout("[]=")
> 
> and then later
> 
> > I plan to introduce 3 additional key bindings:
> >
> > Mod1-f (Apply floating layout)
> > Mod1-m (Apply monocle layout)
> > Mod1-t (Apply tiled layout)
> 
> There already is a notion of the current layout.  Imagine that
> there is also a saved layout and the following function:
> 
> char *resolvelayout(char *proposed)
> {
>     if (proposed == current)
>       proposed = saved;
>     else
>         saved = current;
>     current = proposed;
>     return proposed;
> }
> 
> With this function I can have every target layout toggle:
> 
>     setlayout( resolvelayout("[M]") );
>     setlayout( resolvelayout("[]=") );
>     setlayout( resolvelayout("<><") );
> 
> Just a thought,
> 
> /john
> 

john,

thanks for bothering. I'll have a look at this. I believe that
toggling back and forth is frequently much better than explicit
selection of the desired layout, even for the price of a few lines of
code :-).

joerg

Reply via email to