Function: message-strip-subject-trailing-was
message-strip-subject-trailing-was is a byte-compiled function defined
in message.el.gz.
Signature
(message-strip-subject-trailing-was SUBJECT)
Documentation
Remove trailing "(was: <old subject>)" from SUBJECT lines.
Leading "Re: " is not stripped by this function. Use the function
message-strip-subject-re for this.
Source Code
;; Defined in /usr/src/emacs/lisp/gnus/message.el.gz
;;; Start of functions adopted from `message-utils.el'.
(defun message-strip-subject-trailing-was (subject)
"Remove trailing \"(was: <old subject>)\" from SUBJECT lines.
Leading \"Re: \" is not stripped by this function. Use the function
`message-strip-subject-re' for this."
(or
(let ((query message-subject-trailing-was-query) new)
(and query
(string-match (if (eq query 'ask)
message-subject-trailing-was-ask-regexp
message-subject-trailing-was-regexp)
subject)
(setq new (substring subject 0 (match-beginning 0)))
(or (not (eq query 'ask))
(message-y-or-n-p
"Strip `(was: <old subject>)' in subject? " t
(concat
"Strip `(was: <old subject>)' in subject "
"and use the new one instead?\n\n"
"Current subject is: \"" subject "\"\n\n"
"New subject would be: \"" new "\"\n\n"
"See the variable `message-subject-trailing-was-query' "
"to get rid of this query.")))
new))
subject))