[wmii] dwm Zooms/cycles emulation on wmii

From: Ruben Gonzalez Arnau <ruben_AT_websbarcelona.com>
Date: Wed, 12 Mar 2008 00:35:13 +0100

Hello,

I like this dwm's feature, I create a simple task that does a
'emulation' for wmii (I think), maybe someone to be interested in..

(from dwm manual)

  Mod1-Return
     Zooms/cycles current window to/from master area (tiled layout only).

(for wmii)

$home/wmii-3.5/rc.wmii.local

# get client number
fn getclinum {
         wmiir read /tag/sel/ctl | awk '/^select/ { print $3 ; exit }'
}

# dwm zoom/cycle emulation
fn dwmzoom {
         curclinum=`{getclinum}
         wmiir xwrite /tag/sel/ctl select down
         nextclinum=`{getclinum}

         if(test $curclinum -lt $nextclinum)
                 wmiir xwrite /tag/sel/ctl send sel up
         if not
                 wmiir xwrite /tag/sel/ctl send sel down
}

# Custom keys
fn Key-$MODKEY-Return {
         dwmzoom
}

Of course is a bad code, I just want to learn what is the correct way to
do that.

Any ideas?

Thank you

-- 
Ruben Gonzalez Arnau
GPG key: 0x08AF5CD4 http://www.websbarcelona.com/ruben/0x08AF5CD4.asc

Received on Wed Mar 12 2008 - 00:36:04 UTC

This archive was generated by hypermail 2.2.0 : Sun Jul 13 2008 - 16:37:57 UTC