From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Lennart Borgman Newsgroups: gmane.emacs.devel Subject: Re: word-wrap (visual-line) and indents Date: Tue, 25 May 2010 18:30:25 +0200 Message-ID: References: <9B319A0D-0385-48AD-BF12-884232B365C2@gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1274805823 22075 80.91.229.12 (25 May 2010 16:43:43 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 25 May 2010 16:43:43 +0000 (UTC) Cc: Emacs-Devel devel To: David Reitter Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue May 25 18:43:40 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 1OGxEB-0002Yv-22 for ged-emacs-devel@m.gmane.org; Tue, 25 May 2010 18:43:39 +0200 Original-Received: from localhost ([127.0.0.1]:45995 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OGxEA-0004l2-AF for ged-emacs-devel@m.gmane.org; Tue, 25 May 2010 12:43:38 -0400 Original-Received: from [140.186.70.92] (port=60345 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OGx1p-0003jd-Gx for emacs-devel@gnu.org; Tue, 25 May 2010 12:30:54 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OGx1o-0006Z6-2B for emacs-devel@gnu.org; Tue, 25 May 2010 12:30:53 -0400 Original-Received: from mail-gx0-f220.google.com ([209.85.217.220]:39914) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OGx1n-0006Yz-Vm for emacs-devel@gnu.org; Tue, 25 May 2010 12:30:52 -0400 Original-Received: by gxk20 with SMTP id 20so2375585gxk.12 for ; Tue, 25 May 2010 09:30:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:mime-version:received:in-reply-to :references:from:date:message-id:subject:to:cc:content-type :content-transfer-encoding; bh=0CunmfberSkH+d9DEWDBFvcCTXuGJYQNVfMZLybCNk0=; b=VzZINYvwUzZJ+HtJs48cJzFrMpentw1c4xH7DGemWUEbqMW0GpaAEivztexsDL6MLb r5EE1vncEddubxqNWOyIvRbxPEx9Q2UusOF3go+q6Vaw+ePGd4YOyLyAAX5MWvhM1GYe JDtrhdGUWycvUNAjN8Di/ax+gyJdPSgBtTHJs= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:content-transfer-encoding; b=Nxykg4rVrkljhNvOtoLgXtbO/bu3fITBndTBhEE72/H0pBBvHNBLVej1+HpWY2EoZF eZq7Xlkshz8EcdrX6ZtzlJ9Nfu/zhD4XBDfBvnkdN9ukc1IwiVv+q38TTH+Msb4vF+zY cGvUP1K4CQYDGIiEY2DTKHZZVFVlAugUJCnT8= Original-Received: by 10.100.244.3 with SMTP id r3mr9066198anh.77.1274805046525; Tue, 25 May 2010 09:30:46 -0700 (PDT) Original-Received: by 10.100.177.20 with HTTP; Tue, 25 May 2010 09:30:25 -0700 (PDT) In-Reply-To: <9B319A0D-0385-48AD-BF12-884232B365C2@gmail.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) 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:125255 Archived-At: On Tue, May 25, 2010 at 5:37 PM, David Reitter wr= ote: > Speaking of word-wrapping, I thought now would be a good time to bring up= the missing feature of per-line indentation when word wrapping. > > A recent conversation is quoted below, pointing out that word-wrap is les= s than ideal when it comes to displaying e-mail (and the like). > A similar example would be org-mode, where you would begin a (buffer) lin= e with "- " or " =C2=A0- " =C2=A0and where word-wrap would, ideally, recogn= ize such indentations. > > A buffer-local variable indicating a regexp that matches indentation pref= ixes would be ideal. =C2=A0(As a feature, I would even suggest that if the = regexp has a \\(group\\), the only the length of that group is taken as the= indentation length. > > To display the actual indentation, I think auto-fill-mode used the same p= refix string that was recognized. =C2=A0This was fine for e-mail quotes, bu= t always very annoying visually for lists with "- ". =C2=A0I can see that t= he latter used to be necessary for org-mode, because buffer lines were crea= ted when auto-filling, but the visual word-wrap doesn't have to respect tha= t. > > Indentation with spaces would be sufficient, given that e-mail quotes can= also be highlighted by color. =C2=A0 However, if repeating the prefix is d= esired, then one could make this configurable per buffer (either prefix or = spaces). I have tried to implement this in `wrap-to-fill-column' (which is part of nXhtml currently). Can you test it and see how it fits? I can imagine you may want to split out the indentation part, I just have not done that yet (since no one has seemed very interested until today ;-) ). > On May 24, 2010, at 3:06 PM, Ralf Angeli wrote: >>>> By the way, speaking of nuisances, the lines in your mails are too lon= g >>>> which makes them hard to read. >>> >>> What mail client do you use? >>> If in Emacs, try M-x visual-line-mode. =C2=A0Or set word-wrap to t. >> >> Visual Line mode does not seem to be able to cope with prefixes like >> quote markers. >> >>> I can't predict how wide your window is today, so lines can't be broken= here. > > >