Re: setup desired behavior for alt-tab



On Thu, 29 Dec 2005 07:18:36 +0100, Peter T. Breuer <ptb@xxxxxxxxxxxxxxx> wrote:

chao liu <chaoliu@xxxxxxxx> wrote:
Hi, everyone,

I am using linux FC2 with motif windows manager (mwm), and find that the
alt-tab does not behave like what I want. Suppose there are 3 windows
running, say w1, w2 and w3, and w1 is at the top (i.e. having the current
focus). Then, when I type alt-tab, w2 is brought upfront, which is what I
expect. But when I re-type alt-tab again (with the expectation that w1 gets
focus), it is actually w3 that comes upfront. So I am wondering how I can
change some configuration files so that alt-tab can behave like what I
expect.

I have no idea what or why you expect, but "alt-tab" has always meant "cycle among available windows" in all file managers that emulate a MS windows look and feel. "shift-alt-tab" would cycle in the other direction, which is what you want the second time.

But you usally can alter the default bindings in your window manager - I
don't know how for motif, not using it. But I can certainly say it is
doing what is expected!

There was another post recently with an equivalent question, but the window manager was Fluxbox. I did look into the Fluxbox documentation, but I could not find documented how Fluxbox defines the order of the windows.

If the order is the stacking order, and the window selected by the
:NextWindow command is raised to the top of the stacking order, then,
if :NextWindow is invoked again, the previous top-of-stack window would
be selected.

But if the order is some fixed order of the windows in a table or linked
list inside the window manager, I could not see any way of achieving Windows
semantics with the command set offered in the documentation.

There was a reference to an external tool, wmctrl, which could be used to
write scripts that did more complex operations, but I could not find any
way of querying the window manager about the current stacking order, so
I would only have been able to implement an emulation of the Windows
semantics if *all* operations that change the stacking order are routed
through the external program.

There was an option to list the windows currently managed by the manager,
but the list was the same independent of the window stacking order.

It seems like the easiest way is to hack the source of the window manager
and add a new function, that can subsequently be bound to Alt-Tab. Or, you
could write a script using wmctrl, that would appear to work as desired
provided that no other window raising or lowering operations where made in
the mean time.  That script would need to have some method of saving
the current intended stacking order.

However, the full Windows semantics requires that you can bind actions to
bot keypress and key release. You want to be able to hold down the
alt key while pressing repeatedly on the Tab key, to select any window from
the list, and raise it when the alt key is released.

-Enrique
.



Relevant Pages

  • Re: FLYFF MMO
    ... Anno Domini: ... In the game directory edit the neuz.ini file and add "sunkist 1" without ... OK it does work, BUT, it still leaves alt-tab and the windows key masked ...
    (comp.sys.ibm.pc.games.rpg)
  • Re: What is the best free Linux at this time?
    ... I haven't used Linux since, specially after a couple of GRUB disasters that rendered my whole PC useless until I managed some wizardry to recover my stuff ... One of the things I loved from early Linux was the ample choice of fantastic windows managers such as enlightment with themes. ... Her old G4 that I am using to do WP, internet and mail also on OS-X, but nothing else because after exhaustive research and being called the most incredible names in comp.mac.systems I couldn't actually find any software at any price to do the rest of the things it needed to do. ... It's that proper multitasking you see..sometimes the processor has to do something else..It is obviously a window manager designed by graphic artists FOR graphic artists. ...
    (comp.os.linux.setup)
  • Re: Great SWT Program
    ... Whereas over here I can switch between several ... editing sessions for more than one *type* of thing going concurrently ... very existence of Windows demonstrates, ... Alt-tab doesn't take you to the next file - it takes you to the ...
    (comp.lang.java.programmer)
  • Re: MS Office and Alt-Tab?
    ... Windows in Taskbar setting. ... Hi all - is there any way to set things up so that each office app only ... I hit alt-tab - once is fine. ...
    (microsoft.public.office.misc)
  • Re: Is KDE4 usable on FreeBSD?
    ... My preference is to simply find a window manager that acts as much like ... configuration interface to try to make up for the lacks. ... KDE4 strikes me as significantly counter-intuitive. ... like MS Windows and Apple MacOS X. ...
    (freebsd-questions)