From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Miles Bader Newsgroups: gmane.emacs.devel Subject: display word wrapping Date: Wed, 26 May 2004 19:02:19 +0900 Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: Reply-To: Miles Bader NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1085567491 766 80.91.224.253 (26 May 2004 10:31:31 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 26 May 2004 10:31:31 +0000 (UTC) Original-X-From: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Wed May 26 12:31:25 2004 Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1BSvgz-0003pg-00 for ; Wed, 26 May 2004 12:31:25 +0200 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1BSvgz-00010j-00 for ; Wed, 26 May 2004 12:31:25 +0200 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.34) id 1BSvfk-0002T9-91 for emacs-devel@quimby.gnus.org; Wed, 26 May 2004 06:30:08 -0400 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.34) id 1BSvRB-0008LS-3z for emacs-devel@gnu.org; Wed, 26 May 2004 06:15:05 -0400 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.34) id 1BSvL3-0006Dm-Jr for emacs-devel@gnu.org; Wed, 26 May 2004 06:09:18 -0400 Original-Received: from [202.32.8.202] (helo=TYO202.gate.nec.co.jp) by monty-python.gnu.org with esmtp (Exim 4.34) id 1BSvEt-0003U2-P4; Wed, 26 May 2004 06:02:24 -0400 Original-Received: from mailgate3.nec.co.jp (mailgate53.nec.co.jp [10.7.69.161] (may be forged)) by TYO202.gate.nec.co.jp (8.11.7/3.7W01080315) with ESMTP id i4QA2LY01370; Wed, 26 May 2004 19:02:21 +0900 (JST) Original-Received: (from root@localhost) by mailgate3.nec.co.jp (8.11.7/3.7W-MAILGATE-NEC) id i4QA2LC24935; Wed, 26 May 2004 19:02:21 +0900 (JST) Original-Received: from edtmg04.lsi.nec.co.jp ([10.26.17.201]) by mailsv3.nec.co.jp (8.11.7/3.7W-MAILSV4-NEC) with ESMTP id i4QA2Km09298; Wed, 26 May 2004 19:02:20 +0900 (JST) Original-Received: from mcsss2.ucom.lsi.nec.co.jp (localhost [127.0.0.1]) by edtmg04.lsi.nec.co.jp (8.12.10/8.12.10) with ESMTP id i4QA2JUQ019992; Wed, 26 May 2004 19:02:20 +0900 (JST) Original-Received: from mctpc71 (mctpc71.ucom.lsi.nec.co.jp [10.30.118.121]) by mcsss2.ucom.lsi.nec.co.jp (8.12.10/8.12.8/EDcg v2.01-mc/1046780839) with ESMTP id i4QA2JIm013112; Wed, 26 May 2004 19:02:19 +0900 (JST) Original-Received: by mctpc71 (Postfix, from userid 31295) id 353132D; Wed, 26 May 2004 19:02:19 +0900 (JST) Original-To: emacs-devel@gnu.org System-Type: i686-pc-linux-gnu Blat: Foop Original-Lines: 40 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.4 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:23952 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:23952 Using variable-width fonts more regularly has gotten me musing about display word-wrapping support (for the next version, not this one :-). I've always thought that since the display engine does `proper' wrapping for variable-width characters already (variable-width fonts, tabs, etc), which really seems to work awful darn well, maybe it wouldn't be too hard to trick it into treating words in the buffer as `characters' for wrapping purposes. That seems like it might make everything just work correctly. What I'm wondering is what other support, besides the basic `wrap lines at word boundaries' is needed. * A text-property that defines left/right margins -- with display wrapping the window boundary is probably not exactly right, you often want some whitespace in there. * A way to define how words are divided for the magic wrapping. I suppose it should use syntax tables in some way; I'm not sure are they easy to use or not from the display engine's point of view? I'm thinking that to make things simple, you'd always want to wrap _after_ whitespace (so that it remains editable, but doesn't mess with your left margin) * You probably want to turn off the fringe wrapping glyphs, but maybe not the fringes... * Good support for display-oriented C-n/C-p (I'm not sure existing methods e.g using `vertical-motion' work well with variable-width characters) What else? Just babbling, -Miles -- Any man who is a triangle, has thee right, when in Cartesian Space, to have angles, which when summed, come to know more, nor no less, than nine score degrees, should he so wish. [TEMPLE OV THEE LEMUR]