Re: [As-users] change focus during key mapping

Jason Day (
Fri, 15 Jul 2005 16:39:40 -0400

On Mon, Jul 11, 2005 at 09:17:32AM -0500, Sasha Vasko wrote:
> Try adding FocusOnMap attribute to rxvt style in the database.
> Focusing new windows is considered a security risk, and is avoided by 
> default.

I do this for GRun, but I use a function to grab the focus.  In my feel
file, I have this:

Key F2          A       M       Function "GRun"


Function "GRun"
        Exec            "I" grun &
        Wait            "I" grun
        WarpFore        "I" "grun" "grun"

I assume this is more secure, since GRun doesn't automatically steal the
focus, it only gets focus when invoked in this specific way (someone
please correct me if I'm wrong).  Substitute "rxvt" for "grun" and it
should do what you want.

> Renegade Muskrat wrote:
> >First of all, i'm running AfterStep 2.00.04 on Debian Sarge. I am trying 
> >to map some keys.
> >
> >I have the following line in my feel file:
> >    Key r           A       3       Exec "rxvt" exec rxvt
> >This causes rxvt to run when i press Windows+r. However, rxvt won't 
> >necessarily have focus (i'm using SloppyFocus in my feel file). If 
> >AfterStep places the rxvt window underneath wherever the mouse cursor is 
> >at the time, then rxvt will have focus. Otherwise, rxvt will not have 
> >focus. Is there a way to specify that rxvt should automatically receive 
> >focus when it is run via the key mapping?
Jason Day                                       jasonday at                    worldnet dot att dot net
"Of course I'm paranoid, everyone is trying to kill me."
    -- Weyoun-6, Star Trek: Deep Space 9
As-users mailing list