Function: mh-open-line

mh-open-line is an interactive and byte-compiled function defined in mh-letter.el.gz.

Signature

(mh-open-line)

Documentation

Insert a newline and leave point before it.

This command is similar to the command C-o (open-line) in that it inserts a newline after point. It differs in that it also inserts the right number of quoting characters and spaces so that the next line begins in the same column as it was. This is useful when breaking up paragraphs in replies.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/mh-e/mh-letter.el.gz
(defun mh-open-line ()
  "Insert a newline and leave point before it.

This command is similar to the command \\[open-line] in that it
inserts a newline after point. It differs in that it also inserts
the right number of quoting characters and spaces so that the
next line begins in the same column as it was. This is useful
when breaking up paragraphs in replies."
  (interactive)
  (let ((column (current-column))
        (prefix (mh-current-fill-prefix)))
    (if (> (length prefix) column)
        (message "Sorry, point seems to be within the line prefix")
      (newline 2)
      (insert prefix)
      (while (> column (current-column))
        (insert " "))
      (forward-line -1))))