[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [RP] Re: ratpoison script to show all windows
From: |
Florian Cramer |
Subject: |
Re: [RP] Re: ratpoison script to show all windows |
Date: |
Mon Nov 17 17:44:11 2003 |
User-agent: |
Mutt/1.5.4i |
Am Sonntag, 16. November 2003 um 16:16:44 Uhr (-0600) schrieb Joe Corneli:
> The behavior of your script has one bug I noticed, though. It appears
> that RET doesn't restore the previous layout if one of the windows
> has a `*' in its title (as does this emacs window in which I am
> typing in a buffer called *mail*). This change seems to fix the
> problem.
>
> curframe=`ratpoison -c windows | grep "^.\*" | sed -e "s/^\([0-9]*\)\*.*/\1/"`
Thanks, but I think this wouldn't work as soon you had more than 10
windows open and window no. >10 selected, so I suggest to change it to
curframe=`ratpoison -c windows | grep "^[0-9]*\*" | sed -e
"s/^\([0-9]*\).*/\1/"`
Hacking the script, I noticed that some details in ratpoison could
be improved to allow better external scripting:
- The "windows" and "fselect" commands should behave the same (i.e.
showing window titles and numbers on-screen) as when used
interactively, since this behaviour would be useful for scripts like
rpshowall.
- The commandline/terminal output of "windows" could instead be forked
into a commandline argument, like "ratpoison -l" or "ratpoison
--listwindows".
- The terminal output of the latter could be more informative for
external parsing; it would be great if it could (optionally?) prompt
the group membership and the application ID of a window/frame.
(Maybe the right solution for that would be a format string?!)
Thus it would, for example, possible to write primitive session
management (i.e. restarting all X11 applications used in the
last ratpoison session within the same window/frame/group layout)
for ratpoison via an external script (which could be plumbed into
rp as a startup command and shutdown hook).
-F
--
http://userpage.fu-berlin.de/~cantsin/homepage/
http://www.complit.fu-berlin.de/institut/lehrpersonal/cramer.html
GnuPG/PGP public key ID 3200C7BA, finger address@hidden
Re: [RP] ratpoison script to show all windows, Ryan Yeske, 2003/11/16