You are not logged in.

#1 2009-04-24 18:48:55

Dieter@be
Forum Fellow
From: Belgium
Registered: 2006-11-05
Posts: 2,001
Website

vim-alike keyboard control to your entire environment?

I'm wondering..  Every window manager I've tried, every toolkit and every application (except vi and derivatives) use "insert by default" and keyboard shortcuts like one or more modkeys + extra key to do something at the "meta" level. (eg shortcut to an action in app, or shortcut in your window manager).
Since I'm using keyboard shortcuts quite a lot, that means quite a lot of 2/3-key combinations.

would it be possible to have a vim-like interface for at least your window manager? Can WM's implement this or does this require a change in xorg or so?
So you could do eg 'nt' to go to the next tab instead of modkey+somenumber and "i" to go in "insert mode" (which would pass on all keystrokes to the application except esc), and then it would be the app who would interpret your keystrokes (also in a vim like fashion hopefully)

How does keyboard interpreting happen now? afaik the order of precedence is like this : xorg, WM, focused app. But I'm not sure.


< Daenyth> and he works prolifically
4 8 15 16 23 42

Offline

#2 2009-04-24 19:42:08

Wra!th
Member
Registered: 2009-03-31
Posts: 342

Re: vim-alike keyboard control to your entire environment?

What you are describing is a "modal" control interface.
There are already wm's that implements this (the one I use would be one - Ratpoison)


MacGregor DESPITE THEM!
7f 45 4c 46 01 01 01 00 00 00 00 00 00 00 00 00

Offline

#3 2009-04-24 19:44:57

Hohoho
Member
Registered: 2007-06-23
Posts: 222

Re: vim-alike keyboard control to your entire environment?

And there's ofcourse the Vimperator addon for Firefox smile

Offline

#4 2009-04-24 21:21:08

pauldonnelly
Member
Registered: 2006-06-19
Posts: 776

Re: vim-alike keyboard control to your entire environment?

Wra!th wrote:

What you are describing is a "modal" control interface.
There are already wm's that implements this (the one I use would be one - Ratpoison)

That's Emacs-style, not vi-style, although it might do just as well. You've just got to type a prefix key before commands (which can be a single key). A WM could implement it though, as far as I know. It just has to grab the whole keyboard.

But IMO, OP is just running into the inevitable limitations of trying to use hotkeys for everything.

Offline

#5 2009-04-24 22:07:01

Wra!th
Member
Registered: 2009-03-31
Posts: 342

Re: vim-alike keyboard control to your entire environment?

pauldonnelly wrote:
Wra!th wrote:

What you are describing is a "modal" control interface.
There are already wm's that implements this (the one I use would be one - Ratpoison)

That's Emacs-style, not vi-style, although it might do just as well. You've just got to type a prefix key before commands (which can be a single key). A WM could implement it though, as far as I know. It just has to grab the whole keyboard.

But IMO, OP is just running into the inevitable limitations of trying to use hotkeys for everything.

How is it "Emacs" style and not vi style? Don't you need to use prefix keys in vi(m) to enter certain modes (INSERT, VISUAL, etc)?
Comparing Ratpoison to Emacs is a real punch in the throat sad

Last edited by Wra!th (2009-04-24 22:07:55)


MacGregor DESPITE THEM!
7f 45 4c 46 01 01 01 00 00 00 00 00 00 00 00 00

Offline

#6 2009-04-25 00:25:07

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Re: vim-alike keyboard control to your entire environment?

Isn't ratpoison "gnu screen for X" ? That would mean closer to emacs than to vi..


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#7 2009-04-25 01:25:08

skottish
Forum Fellow
From: Here
Registered: 2006-06-16
Posts: 7,942

Re: vim-alike keyboard control to your entire environment?

Dieter@be,

If you don't feel like coding it yourself, I'd highly recommend contacting the developer(s) of openbox. That project is very responsive to user requests:

http://icculus.org/openbox/index.php/Openbox:Contribute

Offline

#8 2009-04-25 06:06:54

droog
Member
Registered: 2004-11-18
Posts: 877

Re: vim-alike keyboard control to your entire environment?

I looked into this awhile ago and the only real modal wm that could do it right was fvwm from here
http://fvwm.lair.be/viewtopic.php?f=33&t=130
I expanded the last example and it worked fine, for what you are looking for you need something that can change any wm's keys dynamically and i dont think it's possible. unless everyone used fvwm smile

/edit

but fvwm can do anything and everything in 3mb of ram right?

Last edited by droog (2009-04-25 06:24:08)

Offline

#9 2009-04-25 06:29:18

droog
Member
Registered: 2004-11-18
Posts: 877

Re: vim-alike keyboard control to your entire environment?

skottish wrote:

Dieter@be,

If you don't feel like coding it yourself, I'd highly recommend contacting the developer(s) of openbox. That project is very responsive to user requests:

http://icculus.org/openbox/index.php/Openbox:Contribute

somewhat generically since i don't talk to the openbox devs anymore.
I've heard openbox devs say "that would be so easy to include in openbox, but we dont't want to add anything else"
from tiling to whatever.

they are too busy figuring out how to make their menu in xml i think.

Last edited by droog (2009-04-25 06:50:37)

Offline

#10 2009-04-25 17:15:56

Dieter@be
Forum Fellow
From: Belgium
Registered: 2006-11-05
Posts: 2,001
Website

Re: vim-alike keyboard control to your entire environment?

I'm using wmii.  I went to #wmii and asked for advice.  someone suggested i could implement it right in my wmiirc. and he's probably right.
i'm gonna try that smile


< Daenyth> and he works prolifically
4 8 15 16 23 42

Offline

Board footer

Powered by FluxBB