From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: Visual line mode in email citation Date: Mon, 31 May 2010 12:26:42 -0400 Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1275324263 24457 80.91.229.12 (31 May 2010 16:44:23 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 31 May 2010 16:44:23 +0000 (UTC) Cc: emacs-devel@gnu.org To: Uday S Reddy Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon May 31 18:44:21 2010 connect(): No such file or directory Return-path: Envelope-to: ged-emacs-devel@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 1OJ866-0001BL-BZ for ged-emacs-devel@m.gmane.org; Mon, 31 May 2010 18:44:18 +0200 Original-Received: from localhost ([127.0.0.1]:42252 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OJ865-0001iB-Dm for ged-emacs-devel@m.gmane.org; Mon, 31 May 2010 12:44:17 -0400 Original-Received: from [140.186.70.92] (port=46341 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OJ7pl-0002fW-52 for emacs-devel@gnu.org; Mon, 31 May 2010 12:27:32 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OJ7p5-0008Oy-Rf for emacs-devel@gnu.org; Mon, 31 May 2010 12:26:44 -0400 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.183]:36471 helo=ironport2-out.pppoe.ca) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OJ7p5-0008Ok-P6 for emacs-devel@gnu.org; Mon, 31 May 2010 12:26:43 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AvsEAPZ/A0xMCpdY/2dsb2JhbACeMnLAQ4UWBIxMgxU X-IronPort-AV: E=Sophos;i="4.53,334,1272859200"; d="scan'208";a="66310409" Original-Received: from 76-10-151-88.dsl.teksavvy.com (HELO pastel.home) ([76.10.151.88]) by ironport2-out.pppoe.ca with ESMTP; 31 May 2010 12:26:42 -0400 Original-Received: by pastel.home (Postfix, from userid 20848) id 72CB881F8; Mon, 31 May 2010 12:26:42 -0400 (EDT) In-Reply-To: (Uday S. Reddy's message of "Mon, 31 May 2010 10:45:35 +0100") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:125398 Archived-At: > Trying to use the visual line mode in place of longlines isn't working > very well. There are no soft line breaks. So, we end up citing the > entire paragraph as a single line. This is supposed to be ok. > Mail clients like Thunderbird know that the entire paragraph is being > cited and put citation marks on all of it when they do word wrapping. > But, VM and Gnus, depending on Emacs visual-line-mode, have no idea of > what is going on. They end up putting the citation prefix on the > first line of the paragraph, and the remaining lines remain uncited. > Like this paragraph, for example. > Can the visual line mode be taught some email citation issues? This was discussed here a few days ago: the word-wrapping performed by the display engine makes indeed no attempts to recognize citation prefixes (nor indentation), and given the level at which it works, it's better that it doesn't try to do that. OTOH it does provide hooks (more specifically the `wrap-prefix' text-property), which Elisp code can use to make this wrapping do the right thing. IOW, some Elisp code somewhere needs to add a `wrap-prefix' to each line specifying the citation/indentation/fill prefix to use. This should most likely be done by a function passed to jit-lock-register and which then uses something like fill-context-prefix. I'd welcome a patch that provides such a function (e.g. in fill.el) and maybe visual-line-mode could/should use it, but at least Gnus's (and VM's) message display code should use it. Stefan