From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Jason Rumney Newsgroups: gmane.emacs.devel Subject: Re: gtk scroll bar deficiency Date: Thu, 14 Jun 2007 21:30:53 +0100 Message-ID: <4671A57D.5070907@gnu.org> References: <002201c7ae61$5d13fc00$d10990d4@j4f3n1> <87lkemki35.fsf@ambire.localdomain> <00b701c7aea8$72403de0$4a42fe91@j4f3n1> <1088867D-4306-4391-B0D0-E9CF971AE82B@gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1181853078 27575 80.91.229.12 (14 Jun 2007 20:31:18 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 14 Jun 2007 20:31:18 +0000 (UTC) Cc: grischka , emacs-devel@gnu.org To: David Reitter Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Jun 14 22:31:17 2007 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.50) id 1HyvyJ-0004UL-To for ged-emacs-devel@m.gmane.org; Thu, 14 Jun 2007 22:31:12 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HyvyJ-0007jz-Fo for ged-emacs-devel@m.gmane.org; Thu, 14 Jun 2007 16:31:11 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1HyvyF-0007ju-ON for emacs-devel@gnu.org; Thu, 14 Jun 2007 16:31:07 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1HyvyE-0007ji-Mf for emacs-devel@gnu.org; Thu, 14 Jun 2007 16:31:07 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HyvyE-0007jf-If for emacs-devel@gnu.org; Thu, 14 Jun 2007 16:31:06 -0400 Original-Received: from outmail1.freedom2surf.net ([194.106.33.237]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1HyvyE-00051e-6L for emacs-devel@gnu.org; Thu, 14 Jun 2007 16:31:06 -0400 Original-Received: from [127.0.0.1] (i-83-67-23-108.freedom2surf.net [83.67.23.108]) by outmail1.freedom2surf.net (Postfix) with ESMTP id 9719154603; Thu, 14 Jun 2007 21:31:05 +0100 (BST) User-Agent: Thunderbird 2.0.0.0 (Windows/20070326) In-Reply-To: <1088867D-4306-4391-B0D0-E9CF971AE82B@gmail.com> X-detected-kernel: Linux 2.4-2.6 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:72899 Archived-At: David Reitter wrote: > For the scroll-bar, a reasonable estimate would do the job (count line > lengths in various randomly sampled portions of the buffer if the > buffer is big): the scroll-bar is a visual tool and not an exact science. An reasonable estimate is what we have now. If the estimate is wrong, then the results are one of: * User can't scroll to the bottom of the buffer - looks like a bug. * Scrolling jumps near the bottom of the buffer because we tried to fix the above bug. * Scrollbar thumb size changes as you scroll, because we tried to fix the first bug a different way. * Scrolling overshoots because we let the bottom of the buffer scroll to the top of the screen to avoid the above bugs (current behaviour). The only way to improve on that reasonable estimate is to do an exact calculation - which requires pre-rendering the entire buffer to figure out where lines need to wrap, and how tall each line needs to be.