Due to the fact that I could not find any decent editor
outside KDE that behaves just like I wanted, I decided to
try and make
gvim into an xmms front-end. Which naturally meant adding
two macros (one for playing a file and the other for
enqueuing it) into my .vimrc file.

I knew Vim macros were basically a recording of all the
commands needed to execute them. So, after consulting the
vim help pages a bit I came up with a
generic macro that did just that. This macro had a
problem in which it was not resistant to shell's special
characters.

I worked on two other revisions of the macro. In the
third revision everything was fixed except for filenames
that contain newlines (which are pretty rare as it is).

What I did was copy the line containing the filename into
a register, duplicate it below, substitute all the single
quotes with the sequence '\'', copy it into the register
again. Then, I entered the command line :!xmms '$reg' on the
shell, and afterwards deleted the extra line.

Guy Keren
once said to me that one did not do real programming until
he programs with Vi macros. So, perhaps this was a baby step
in the direction of becoming a "real" programmer.