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: Pixel-based display functions Date: Fri, 06 Feb 2015 10:18:00 -0500 Message-ID: References: <837fw3l7uz.fsf@gnu.org> <54CD4B27.4080201@gmx.at> <874mr6qvi5.fsf@building.gnus.org> <87sieqpfxh.fsf@building.gnus.org> <54CDE908.7050908@gmx.at> <87ioflq0dz.fsf@building.gnus.org> <54CE2187.9070003@gmx.at> <83lhkhiq8t.fsf@gnu.org> <54CE54A3.1020707@gmx.at> <838ughilmo.fsf@gnu.org> <54CE6BD2.8000402@gmx.at> <8361bliin0.fsf@gnu.org> <83386piiby.fsf@gnu.org> <87oap9yoti.fsf@building.gnus.org> <874mqzvnwo.fsf@building.gnus.org> <83h9uzeb4a.fsf@gnu.org> <87bnl7jrr7.fsf@building.gnus.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1423235923 31827 80.91.229.3 (6 Feb 2015 15:18:43 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 6 Feb 2015 15:18:43 +0000 (UTC) Cc: rudalics@gmx.at, Eli Zaretskii , emacs-devel@gnu.org To: Lars Ingebrigtsen Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Feb 06 16:18:38 2015 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1YJkg1-0004Ps-NT for ged-emacs-devel@m.gmane.org; Fri, 06 Feb 2015 16:18:37 +0100 Original-Received: from localhost ([::1]:48910 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YJkg0-00038s-W1 for ged-emacs-devel@m.gmane.org; Fri, 06 Feb 2015 10:18:36 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:51784) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YJkfc-0002xp-5K for emacs-devel@gnu.org; Fri, 06 Feb 2015 10:18:19 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YJkfW-0002Xf-CD for emacs-devel@gnu.org; Fri, 06 Feb 2015 10:18:12 -0500 Original-Received: from pruche.dit.umontreal.ca ([132.204.246.22]:33306) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YJkfW-0002Xa-7T; Fri, 06 Feb 2015 10:18:06 -0500 Original-Received: from pastel.home (lechon.iro.umontreal.ca [132.204.27.242]) by pruche.dit.umontreal.ca (8.14.1/8.14.1) with ESMTP id t16FI1dT008611; Fri, 6 Feb 2015 10:18:01 -0500 Original-Received: by pastel.home (Postfix, from userid 20848) id E186FFAD; Fri, 6 Feb 2015 10:18:00 -0500 (EST) In-Reply-To: <87bnl7jrr7.fsf@building.gnus.org> (Lars Ingebrigtsen's message of "Fri, 06 Feb 2015 20:47:40 +1100") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) X-NAI-Spam-Flag: NO X-NAI-Spam-Threshold: 5 X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 1 Rules triggered RV5209=0 X-NAI-Spam-Version: 2.3.0.9393 : core <5209> : inlines <2043> : streams <1385758> : uri <1848116> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 132.204.246.22 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:182537 Archived-At: > shr inserts text as long lines into the buffer, and I then use > `vertical-motion' to go to the desired width, and then backtracking > finding a fill point using the kinsuko algorithm. Then a newline is > inserted, and we repeat until the line is completely filled. That sounds OK. It should end up considering an amount of text O(N), with very little wasted work (the only wasted work is on the text before fill-column but after the chosen fill point). I'm not sure if vertical-column might waste some extra time on the vertical movement (which you don't need), but other than that, it should be about as fast as you can get. IOW, if it's not fast enough, your next best chance is lazyness ;-) Stefan