From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Adam Funk Newsgroups: gmane.emacs.help Subject: fill-paragraph in USENET messages (was: Quotelength with slrn and vim) Date: Mon, 09 Aug 2010 20:21:47 +0100 Organization: $CABAL Message-ID: References: <1mg3j7xuou.ln2@news.ducksburg.com> NNTP-Posting-Host: lo.gmane.org X-Trace: dough.gmane.org 1291857283 1554 80.91.229.12 (9 Dec 2010 01:14:43 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 9 Dec 2010 01:14:43 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Dec 09 02:14:37 2010 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PQV5d-0007RA-VD for geh-help-gnu-emacs@m.gmane.org; Thu, 09 Dec 2010 02:14:34 +0100 Original-Received: from localhost ([127.0.0.1]:35134 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PQV5d-0003PB-BO for geh-help-gnu-emacs@m.gmane.org; Wed, 08 Dec 2010 20:14:33 -0500 Original-Path: usenet.stanford.edu!sol01.ashbva.gweep.ca!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail Original-Newsgroups: news.software.readers,gnu.emacs.help Original-Lines: 40 Original-X-Trace: individual.net nm+mRn9XTTHoAkMb5805nQcU6hDpwEg6mlluDDVVW/pMUMHyqJ X-Orig-Path: news.ducksburg.com!not-for-mail Cancel-Lock: sha1:+WDIjBqu7JzDeymX857nOO5TsBM= sha1:Hcm3NsxnPJ3CF8PF2gXKbDobQJo= User-Agent: slrn/pre1.0.0-16/mm/ao (Ubuntu Intrepid) Original-Xref: usenet.stanford.edu news.software.readers:264347 gnu.emacs.help:180521 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:76361 Archived-At: [I'm adding gnu.emacs.help in case this is useful to someone outside of NSR --- please feel free to prune FUs.] On 2010-08-08, Adam Funk wrote: > If I put the cursor in a section of text with a blank line before and > after it, and press M-q, emacs will reformat ("fill") it and preserve > the number of ">" at the beginning of each line --- which I've just > done to your lines above. Unfortunately, it doesn't correctly > identify the "paragraph" to reformat if there are non-blank lines > containing only ">" and spaces that make it contiguous with other > paragraphs with different levels of quoting. Well, I just found the following in my ~/.emacs file #v+ ;; Message-ID: ;; From: Matthew Flaschen ;; gnu.emacs.help 2007-03-19 ;; Subject: Re: Configuring fill-paragraph not to mash the subversion delimiter? (setq paragraph-start (concat paragraph-start "\\|--This line, and those below, will be ignored--")) (setq paragraph-separate (concat paragraph-separate "\\|--This line, and those below, will be ignored--")) #v- and thought I might be able to string something together to deal with adjacent quoted text in news posts. #v+ (setq paragraph-start (concat paragraph-start "\\|[> \t]*\\(-- *\\)?$")) (setq paragraph-separate (concat paragraph-start "\\|[> \t]*\\(-- *\\)?$")) #v- That seems to do what I want, but I welcome improvements. -- The three-martini lunch is the epitome of American efficiency. Where else can you get an earful, a bellyful and a snootful at the same time? [Gerald Ford, 1978]