GNU bug report logs -
#34387
26.1; Gnus: handle empty message parts
Previous Next
Full log
Message #23 received at 34387 <at> debbugs.gnu.org (full text, mbox):
On Wed, 13 Feb 2019 18:26:44 +0100, Christophe Troestler wrote:
> Thanks for your analysis. I indeed had an advice executed after
> mm-shr to remove trailing whitespace—these making sometimes the
> rendered text hard to read. Deleting the advice makes the call
> work.
Bingo! :)
> What approach would you recommend to remove trailing whitespace
> after rendering HTML?
The point would be to delete only whitespace that mm-shr inserts.
How about this?
(defadvice mm-shr (around delete-leading-and-trailing-whitespace activate)
"Delete leading and trailing whitespace in Gnus article buffer."
(when (derived-mode-p 'gnus-article-mode)
(save-restriction
(narrow-to-region (point) (point))
ad-do-it
(goto-char (point-min))
(skip-chars-forward "\t\n ")
(delete-region (point-min) (point))
(goto-char (point-max))
(skip-chars-backward "\t\n ")
(delete-region (point) (point-max))
(insert "\n"))))
I'll close this thread after fixing the other two related bugs.
> 1. In the article buffer, pressing the RET key on an empty
> text/plain attachment conceals the succeeding other attachments,
> does not toggle. `g' restores them of course, though.
> 2. Some kind of an empty mail isn't able to be edited using the
> `e' command (gnus-summary-edit-article), that is, a single part
> email whose body is an empty attachment. Gnus misunderstands
> that the header is its body.
Regards,
This bug report was last modified 6 years and 97 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.