Re: [dwm] Preventing xterm from closing by killclient()

From: Jeremy O'Brien <obrien654j_AT_gmail.com>
Date: Wed, 9 Apr 2008 19:17:06 -0400

I recommend looking in applyrules() for some example code. You may be
able to adapt it in killclient() :)

On Apr 9, 2008, at 18:56, Martin Sander <forke_AT_uni-bonn.de> wrote:

> On Wed, Apr 09, 2008 at 11:25:59PM +0200, Anselm R. Garbe wrote:
>> Hmm, what about changing the binding to Ctrl-d in your setup
>> then?
>
> Thanks for the suggestion, but I think I did not make myself entirely
> clear. My problem is of different nature.
>
> As an example, I have an xterm with an ipython [2] shell, which I
> use to
> plot some data using matplotlib [2]. The window showing the plot has
> no
> means of closing it but killclient() (the same with gnuplot, btw).
>
> So when I want to close that window I use MODKEY|Shiftmask, XK_c.
> My problem occurs when I don't realize that actually that window is
> not
> focused, but the xterm running ipython is focused instead.
> xterm closes, I lose everything I have typed in that window so far,
> including the history, which is absolutely not what I want.
>
> I know I could use BORDERPX > 2 or set SELBORDERCOLOR to something
> very
> high contrast, but I'd find that rather distracting/ugly.
>
> I'd prefer just to never ever kill xterm, something like
>
> if (clientname=='xterm')
> return;
>
> in killclient(). I just need some hints how to do it.
>
> Regards
>
> Martin
>
> [1] http://ipython.scipy.org/
> [2] http://matplotlib.sourceforge.net/
>
>
Received on Thu Apr 10 2008 - 01:18:09 UTC

This archive was generated by hypermail 2.2.0 : Sun Jul 13 2008 - 15:32:50 UTC