El dc, mar 18 2009, Charles Cave va escriure: > > (defun prefix-region (prefix) > "Add a prefix string to each line between mark and point." > …
To do this I use: 1. Put mark at the first line's beginning and point at the last line's beginning 2. C-x r t 3. Type your prefix, ENTER ,---- | C-x r t runs the command string-rectangle, which is an interactive autoloaded | Lisp function in `rect.el'. | | It is bound to C-x r t. | | (string-rectangle START END STRING) | | Replace rectangle contents with STRING on each line. | The length of STRING need not be the same as the rectangle width. `---- It allows not only to prefix but also to „infix“ and „suffix“, and to replace rectangles of text. Also nice is C-x r k, to delete a rectangular region. And C-x r y, etc. -- Daniel _______________________________________________ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode