[mew-int 2895] Re: mew-wrap-lines

Michael Ernst <[email protected]> Wed, 28 Jul 2010 21:28:14 -0700 (PDT)
Newsgroups gmane.mail.mew.general
Message-ID <[email protected]>
Christophe-

> > Is there a way to tell mew to remove the dashes (and maybe "*") from
> > filling prefix?  This would be a nice thing to have.

Your code is useful, thanks a lot!

A minor point:  it's error-prone to pass a string that might contain "%" as
the first argument to the message function.  (It crashed for me soon after
I started using it.)  Here is a very tiny tweak to the given code.  I also
eliminated the need for the add-hook form.


(defadvice mew-fill-match-adaptive-prefix
  (after mew-remove-itemize-chars activate)
  "Remove the symbols commonly used as indicators for itemize lists from
the prefix used for filling messages."
  (message "%s" ad-return-value)
  (setq ad-return-value
	(replace-regexp-in-string "[-*]" " " ad-return-value)))


		    -Mike