From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Luc Teirlinck Newsgroups: gmane.emacs.devel Subject: Re: Gtk scrollbar: thumb too short Date: Mon, 31 Mar 2003 18:28:48 -0600 (CST) Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: <200304010028.h310Sm210574@eel.dms.auburn.edu> References: <20030325193739.ZGIN3924.fep01-svc.swip.net@gaffa.gaia.swipnet.se> <3E8345E8.4090509@swipnet.se> <1048872463.17161.132.camel@localhost.localdomain> <1049134327.3326.74.camel@localhost.localdomain> NNTP-Posting-Host: main.gmane.org X-Trace: main.gmane.org 1049157088 4103 80.91.224.249 (1 Apr 2003 00:31:28 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Tue, 1 Apr 2003 00:31:28 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Tue Apr 01 02:31:26 2003 Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1909gU-000142-00 for ; Tue, 01 Apr 2003 02:31:26 +0200 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by quimby.gnus.org with esmtp (Exim 3.12 #1 (Debian)) id 1909gp-0002ov-00 for ; Tue, 01 Apr 2003 02:31:48 +0200 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 1909eL-0004Mx-03 for emacs-devel@quimby.gnus.org; Mon, 31 Mar 2003 19:29:13 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.10.13) id 1909dJ-0003ar-00 for emacs-devel@gnu.org; Mon, 31 Mar 2003 19:28:09 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.10.13) id 1909dC-0003SE-00 for emacs-devel@gnu.org; Mon, 31 Mar 2003 19:28:04 -0500 Original-Received: from manatee.dms.auburn.edu ([131.204.53.104]) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 1909d1-0003IF-00; Mon, 31 Mar 2003 19:27:51 -0500 Original-Received: from eel.dms.auburn.edu (eel.dms.auburn.edu [131.204.53.108]) h310Rnoc013092; Mon, 31 Mar 2003 18:27:50 -0600 (CST) Original-Received: (from teirllm@localhost) by eel.dms.auburn.edu (8.11.6+Sun/8.11.6) id h310Sm210574; Mon, 31 Mar 2003 18:28:48 -0600 (CST) X-Authentication-Warning: eel.dms.auburn.edu: teirllm set sender to teirllm@dms.auburn.edu using -f Original-To: otaylor@redhat.com In-reply-to: <1049134327.3326.74.camel@localhost.localdomain> (message from Owen Taylor on 31 Mar 2003 13:12:07 -0500) Original-cc: rms@gnu.org Original-cc: jan.h.d@swipnet.se Original-cc: kai.grossjohann@uni-duisburg.de X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1b5 Precedence: list List-Id: Emacs development discussions. List-Help: List-Post: List-Subscribe: , List-Archive: List-Unsubscribe: , Errors-To: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:12786 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:12786 Owen Taylor wrote: While you may think of the scrollbar as a miniature view of the document, it is also presented to the user as a physical control, with obvious limits as to how far the scrollbar can be dragged. I believe that this all boils down to the difference between (1) a character and (2) a pixel based philosophy. For efficiency reasons, Emacs has no choice but to adopt (1). Given that, it should do it consistently, otherwise things would become unpredictable. For (1) the thumb indicates the percentage of total "content" contained in the part of the buffer that is represented above, on and below the screen. I believe that for (2) the thumb indicates how much more upward and downward scrolling is possible, regardless of how much extra content that is going to bring into view. Start with an empty buffer in a window that has room for 60 lines of regular character size and type: a NEWLINE b I believe that according to (1) the thumb should still cover the entire length of the scrollbar, but according to (2), it should only cover the top 60/61 of the scrollbar. That is because there is now one extra screen line we can scroll down to and according to the visually based philosophy of (2), that matters. According to the character based philosophy of (1), there are no extra characters that can be brought into view, even though extra scrolling is possible. Now scroll the second line to the top. One screen line, two characters, scrolled of the screen. We still have one third of the characters on the screen, so for (1), the thumb should occupy the bottom one third. This is exactly what happens for the native scrollbar. (I do not see why the knob should "pop out of the trough". The overscrolled piece contains no characters, so according to (1) its size is 0, it does not really "exist", it is an optical illusion.) For (2), I believe the thumb should occupy the bottom 60/61 of the scrollbar. Actually, I believe that for (2) mere scrolling should not change the size of the thumb. I believe that it is correct for the default behavior of GTK to be pixel based, since it is more "intuitive" and covers the needs of more applications. I believe that the question is whether somehow one could increase the "customizability" of the GTK scrollbar, to make it possible, to have it, within Emacs, better approximate the native scrollbar, without negatively affecting its interaction with applications that want a pixel based behavior. Alternatively, people who prefer the consistently character based behavior (compared, not with a consistently pixel based philosophy, but with some inconsistent and unpredictable mixture) could use the native scrollbar (as I do). Sincerely, Luc.