Personal tools
You are here: Home



 
Showing blog entries tagged as: lisp

An Emacs cheatsheet as a mindmap

I have been using Emacs for some time now. It has a very steep learning curve, but its power and elegance make it my editor of choice for just about everything. So, inspired by this article, I decided to create my own Emacs cheatsheet. There are many Emacs cheatsheets, but all of them use a tabular format that is not, in my noob opinion, the best way to convey such information: you can interpret the Emacs commands as a tree-like keystroke structure and many important commands use two or more steps.

I started a mind-map for the keystroke trees with the commands I use the most (and some of the ones I find the most amusing). The plan is to make a navigable cheat sheet like the Mercurial and Git ones you can get here and here, plus some tips on what to add to your ~/emacs.d/init.el file.

You can get the very, very early version of the mind-map (in Freemind format) here or just look into the image that follows.

All the heavy magic is also missing, like the "smart paste" Marco Baringer does about 1:45 into the What is Ajax screencast that relates to the David Crane's Ajax in Action book (that I still don't know how is done).

Mind-map for a future Emacs cheatsheet

I would appreciate any advice from Emacs veterans and newbies alike, so, feel free to comment.

Read More…

Editor nirvana

To say GNU Emacs is merely a text editor is an understatement. Ever since I decided I would learn to use it (out of a never quite accomplished mission of learning Lisp once and for all), it impresses me almost on a daily basis.

Yesterday, while playing with my choice of screen fonts for the editor (something every bit as important as choosing one's text editor), I discovered two pop-up menu options, to increase and decrease font size. A little playing with Meta-X and I arrived a couple functions, "text-scale-increase" and "text-scale-decrease". A little more digging brought me to the key combinations "Control X Control plus" and "Control X Control minus" sequences. Usable, but I wanted something easier to type.

Few non-Emacs users appreciate the fact Emacs has no configuration file. What it has is a program, in its own Lisp dialect, that's executed every time the editor is started. Within this program I can define new functions, load external libraries and even write a credible implementation of vi. This time I made two simple edits to my init.el file that added two new key bindings:

(global-set-key (kbd "C--") 'text-scale-decrease)
(global-set-key (kbd "C-+") 'text-scale-increase)

The first one binds the "Control minus" key combination to the text-scale-decrease function (that decreases text size) while the second binds "Control plus" to the opposite text-scale-increase function. Easy enough for me. Now, every time Emacs starts, it has a couple bindings extra key bindings (on top of all other already added by loading external libraries, modules and so on) that make my life more convenient.

And this concludes my Emacs praise of the day. Thanks for coming.

Read More…

O Kanamit Web Framework

Eu sempre gostei de escrever aqui sobre linguagens "exóticas". Já houve um tempo em que Python era exótico. Hoje Python é mainstream. Ruby, idem. Há até suporte a Rails no NetBeans 6 e para Python no Visual Studio. Não dá pra ser muito mais mainstream do que isso.

Read More…

Projetos para as Férias

Posted by Ricardo Bánffy at Dec 28, 2006 11:30 AM |

Sugestões para programadores em busca de horizontes mais largos

Read More…