I really like the rxvt-unicode (urxvt) terminal window for X11. I’ve been extending it a lot for my own needs. There’s only one glaring piece of functionality that seems to require the mouse: scrolling and selecting text. I thought I’d remedy that.
In my ideal world, I’d be able to press Scroll Lock, and then use vi key bindings to move the cursor around, scroll back in the history, and select text for the clipboard without ever touching the mouse. When I’m done, Escape or Scroll Lock again should take me back to normal terminal operation.
So be it. If you install the extension from one of the links below, that’s what you get out of the box. That’s why I called it “urxvi”.
But! I know that some of my keyboard-centric brothers and sisters live on the other side of the denominational divide known as the editor wars, preferring emacs or some other editor. Thus, I have made urxvi’s key bindings and behavior completely configurable. All you have to do is provide your own rcfile for the purpose. I’ve even provided the default bindings through a global rcfile (urxvirc), to serve as a starting point.
I probably went a little overboard on the scripting language used in the rcfile.
I call it Slips, for “Sloppy Lisp.” It’s an S-expression syntax, but with not so much punctuation as Lisp. It includes a lot of neat features (like lamdbas and witheringly lazy evaluation), along with a lot of glaring omissions (like list processing and I/O). It’s basically everything I needed to create the default key bindings, plus a few extras. I’ll add functionality to this mini-language as it’s required.
Implementing a pseudo-Lisp interpreter in Perl brought me closer in tune with the true nature of the Universe, especially since I did it in such a sloppy fashion. This certainly isn’t turtles all the way down — more like turtles afraid to reach second base. Actually, I was surprised at how well Perl served this purpose, especially considering my own lack of Perl-fu.