From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#25308: Shorten long "ui-lines" in Custom buffers Date: Sat, 31 Dec 2016 15:57:28 +0200 Message-ID: <83o9zsgq0n.fsf@gnu.org> References: <87eg0o2psh.fsf@bernoul.li> Reply-To: Eli Zaretskii NNTP-Posting-Host: blaine.gmane.org X-Trace: blaine.gmane.org 1483192695 23847 195.159.176.226 (31 Dec 2016 13:58:15 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 31 Dec 2016 13:58:15 +0000 (UTC) Cc: 25308@debbugs.gnu.org To: Jonas Bernoulli Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Dec 31 14:58:12 2016 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cNKAi-0005C6-6C for geb-bug-gnu-emacs@m.gmane.org; Sat, 31 Dec 2016 14:58:08 +0100 Original-Received: from localhost ([::1]:44199 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cNKAn-0006CP-8h for geb-bug-gnu-emacs@m.gmane.org; Sat, 31 Dec 2016 08:58:13 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:46503) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cNKAh-0006CA-6g for bug-gnu-emacs@gnu.org; Sat, 31 Dec 2016 08:58:08 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cNKAc-0002hU-Bp for bug-gnu-emacs@gnu.org; Sat, 31 Dec 2016 08:58:07 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:45521) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cNKAc-0002hN-8T for bug-gnu-emacs@gnu.org; Sat, 31 Dec 2016 08:58:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1cNKAc-0003vI-2J for bug-gnu-emacs@gnu.org; Sat, 31 Dec 2016 08:58:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 31 Dec 2016 13:58:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 25308 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 25308-submit@debbugs.gnu.org id=B25308.148319266115050 (code B ref 25308); Sat, 31 Dec 2016 13:58:02 +0000 Original-Received: (at 25308) by debbugs.gnu.org; 31 Dec 2016 13:57:41 +0000 Original-Received: from localhost ([127.0.0.1]:60920 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cNKAH-0003ug-FM for submit@debbugs.gnu.org; Sat, 31 Dec 2016 08:57:41 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:55450) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cNKAF-0003uQ-JK for 25308@debbugs.gnu.org; Sat, 31 Dec 2016 08:57:39 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cNKA4-0002M0-Tp for 25308@debbugs.gnu.org; Sat, 31 Dec 2016 08:57:33 -0500 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:46495) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cNKA4-0002Lu-Qk; Sat, 31 Dec 2016 08:57:28 -0500 Original-Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:1157 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1cNKA4-00008V-3Q; Sat, 31 Dec 2016 08:57:28 -0500 In-reply-to: <87eg0o2psh.fsf@bernoul.li> (message from Jonas Bernoulli on Sat, 31 Dec 2016 14:26:06 +0100) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:127625 Archived-At: > From: Jonas Bernoulli > Date: Sat, 31 Dec 2016 14:26:06 +0100 > > Custom buffers contain two long lines, the first separating the initial > buttons from the options shown below, and the second is for symmetry, I > suppose. This is implemented in `custom-group-value-create'. > > These lines are 999 characters long. When point ends up on the "line > line", then it ends up at the *end* of that line, scrolling all content > except for the line itself off-window. This happens both with C-n/C-p, > as well as when using the mouse scroll wheel. The scrolling only happens for me if I set truncate-lines to a non-nil value. Is that what you see? Or perhaps you invoke Customize in a partial-width window, in which case truncate-partial-width-windows is non-nil by default? If lines are not truncated, there's no horizontal scrolling. > If that is considered to be too ugly, then I would suggest setting the > `:align-to' to be just long enough to reach the edge of the window (but > never longer) at the time `custom-group-value-create' is called, using > something like: > > (list 'space :align-to > `(+ (0 . right) > ,(min (window-hscroll) > (- (line-end-position) > (line-beginning-position))))) Does this really work when a window has its lines truncated?