Dear brothers and sisters of faith: Some temptations are trying to drag
me away from The One True Editor. My problem is this:
As you already know, most major modes of emacs make quite sensible
indentations. I only need to go to the beginning of each line and then
press Tab-key. But how can I have it done automatically? I mean
something like this:
1) I open some file to emacs
2) I give some line-command (via M-x or otherwise) and it runs this
algorithm:
2.1) Move cursor to the beginning of first line.
2.2) Edit that line in that way how pressing Tab-key would edit it in
current major-mode.
2.3) Move cursor to the beginning of next line
2.4) Edit that line in that way how pressing Tab-key would edit it in
current major-mode.
2.5) If we are not in the last line of buffer, go to step 2.3
2.6) If we are in the last line of buffer, exit from this algorithm.
2) I save that file.
In addition, it would be nice, if in SGML-, XML- and HTML-modes
everything between <pre> -tags were skipped by that algorithm. It is not
fun, if some unwanted indentations are added there, because WWW-browsers
will show them, too.
--
Juhapekka "naula" Tolvanen * http colon slash slash iki dot fi slash
juhtolv
"S teki. S teki. S teki. S wo kakusei. S teki. S teki. S teki. S wo
umekome.
S teki. S teki. S teki. M wo setsudan. S teki. S teki. Puratonikku wo
hajimemashou." Dir en
grey


|