[comp.mail.elm] Emacs and elm Gnu emacs, that is

froehlig@skat.usc.edu (Bob Froehlig) (06/14/91)

dbasinge@silver.ucs.indiana.edu (Mike Basinger) writes:

>I have elm set up to use emacs as a editor. My question is, when I
>type a message in mail, emacs will not line-wrap. Emacs will line-wrap
>files outside of elm though.
>Can someone tell me how to set up elm emacs to line-wrap.

If you mean auto-fill by line-wrap, we had an elm user here who had the same
request.  I looked at the source (editmsg.c) to see if there were support for
a suffix function specifier for gnu emacs ("-f turn-on-auto-fill"), but found
there was no such support (yet).  I have submitted a patch for elm 2.4.

For the time being, we've had users modify their ~/.emacs files to do
something like this:

    (defun text-and-auto-fill-mode ()
      (text-mode)
      (turn-on-auto-fill))
    (setq auto-mode-alist
	  (append
	   '(("/snd.[0-9]+$" . text-and-auto-fill-mode))
	   auto-mode-alist))

Or if you prefer, you could just use:

    (setq default-major-mode 'text-mode)
    (setq text-mode-hook '(lambda () (turn-on-auto-fill)))

but that has larger ramifications outside of elm.  I hope that it's of help.
----
Bob Froehlig			    	internet: bobf@usc.edu
 University Computing Services		University of Southern California