Re: [dwm] Focus follows mouse

2009-01-22 Thread stanio
* Premysl Hruby  [2009-01-20 12:15]:
> On (20/01/09 12:08), sta...@cs.tu-berlin.de wrote:
> > Can anybody give a sketch how to achieve this in dwm (or give a hint where
> > to look at in the source)?
> 
> Hi, to disable follow mouse behaviour, simply comment off:
> 
>   [EnterNotify] = enternotify,
> 
> in definiton of struct handler in dwm.c (or you can this and whole
> enternotify() delete).

That is what I did.
Thanks a lot!

> Alternatively, you can define some new toggle in
> dwm.c, write some control function for toggling (so you can toggle
> follow mouse on/off with keypress) and put something like:
> 
>   if(!followMouse)
>   return;
> 
> into enternotify();

I have never needed this behaviour in the past, and past is often a good
estimate for the future :o)

-- 
 cheers
 stanio_



Re: [dwm] Focus follows mouse

2009-01-20 Thread Premysl Hruby
On (20/01/09 12:08), sta...@cs.tu-berlin.de wrote:
> To: dwm mail list 
> From: sta...@cs.tu-berlin.de
> Subject: [dwm] Focus follows mouse
> Reply-To: dwm mail list 
> List-Id: dwm mail list 
> User-Agent: Mutt/1.5.18 (2008-05-17)
> 
> Hi,
> 
> At the time I switched from wmii back to dwm I was evaluating couple of
> other WM from the family and I liked a feature I cannot currently tell
> where it was (but I suspect it was Xmonad): switch off the
> focus-follows-mouse behaviour.
> 
> Can anybody give a sketch how to achieve this in dwm (or give a hint where
> to look at in the source)?
> 
> Thanx in advance!
> 

Hi, to disable follow mouse behaviour, simply comment off:

[EnterNotify] = enternotify,

in definiton of struct handler in dwm.c (or you can this and whole
enternotify() delete). Alternatively, you can define some new toggle in
dwm.c, write some control function for toggling (so you can toggle
follow mouse on/off with keypress) and put something like:

if(!followMouse)
return;

into enternotify();

-Ph

-- 
Premysl "Anydot" Hruby, http://www.redrum.cz/