unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#14324: 24.3; GTK scrollbar doesn't scroll proportionally when Line Wrapping is set to "Truncate Long Lines"
@ 2013-04-30 17:02 j.pertres
  2013-05-09 19:33 ` Stefan Monnier
  2021-05-31  6:03 ` Lars Ingebrigtsen
  0 siblings, 2 replies; 11+ messages in thread
From: j.pertres @ 2013-04-30 17:02 UTC (permalink / raw)
  To: 14324


To reproduce:
  1. Visit a buffer with very long lines, and long enough to make Emacs render a
  vertical scrollbar
  2. In the Options menu, set the option "Line Wrapping" to "Truncate
  Long Lines"
  3. Drag the scrollbar to navigate the file. Emacs won't scroll
  proportionally, but rather get stuck at some points, seemingly at
  those very long lines, maybe as if they were still shown in multiple
  lines, even though now they don't.

In GNU Emacs 24.3.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.6.4)
 of 2013-03-18 on eric
Windowing system distributor `The X.Org Foundation', version 11.0.11401000
Configured using:
 `configure '--prefix=/usr' '--sysconfdir=/etc' '--libexecdir=/usr/lib'
 '--localstatedir=/var' '--with-x-toolkit=gtk3' '--with-xft'
 'CFLAGS=-march=x86-64 -mtune=generic -O2 -pipe -fstack-protector
 --param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2'
 'LDFLAGS=-Wl,-O1,--sort-common,--as-needed,-z,relro''

Important settings:
  value of $LANG: ca_ES.utf8
  value of $XMODIFIERS: @im=ibus
  locale-coding-system: utf-8-unix
  default enable-multibyte-characters: t

Major mode: Slim

Minor modes in effect:
  tooltip-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t

Recent input:
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <help-echo> <down-mouse-1> 
<mouse-1> <help-echo> <help-echo> <help-echo> <help-echo> 
<help-echo> C-x 1 <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> <mouse-1> 
<mouse-1> M-x r e p o r t - e m a c s - b u g <ret
urn>

Recent messages:
Quit
Making completion list...
byte-code: End of buffer
Using vacuous schema
Truncate long lines enabled
Truncate long lines disabled
byte-code: End of buffer [2 times]
byte-code: Beginning of buffer [2 times]
call-interactively: End of buffer
Undo!

Load-path shadows:
/usr/share/emacs/site-lisp/cedet/speedbar/sb-image hides /usr/share/emacs/24.3/lisp/sb-image
/usr/share/emacs/site-lisp/cedet/speedbar/dframe hides /usr/share/emacs/24.3/lisp/dframe
/usr/share/emacs/site-lisp/cedet/common/ezimage hides /usr/share/emacs/24.3/lisp/ezimage
/usr/share/emacs/site-lisp/cedet/speedbar/speedbar hides /usr/share/emacs/24.3/lisp/speedbar
/usr/share/emacs/site-lisp/cedet/eieio/eieio-datadebug hides /usr/share/emacs/24.3/lisp/emacs-lisp/eieio-datadebug
/usr/share/emacs/site-lisp/cedet/eieio/eieio-speedbar hides /usr/share/emacs/24.3/lisp/emacs-lisp/eieio-speedbar
/usr/share/emacs/site-lisp/cedet/eieio/eieio-opt hides /usr/share/emacs/24.3/lisp/emacs-lisp/eieio-opt
/usr/share/emacs/site-lisp/cedet/eieio/chart hides /usr/share/emacs/24.3/lisp/emacs-lisp/chart
/usr/share/emacs/site-lisp/cedet/eieio/eieio-base hides /usr/share/emacs/24.3/lisp/emacs-lisp/eieio-base
/usr/share/emacs/site-lisp/cedet/eieio/eieio-custom hides /usr/share/emacs/24.3/lisp/emacs-lisp/eieio-custom
/usr/share/emacs/site-lisp/cedet/eieio/eieio hides /usr/share/emacs/24.3/lisp/emacs-lisp/eieio
/usr/share/emacs/site-lisp/cedet/common/pulse hides /usr/share/emacs/24.3/lisp/cedet/pulse
/usr/share/emacs/site-lisp/cedet/semantic/semantic hides /usr/share/emacs/24.3/lisp/cedet/semantic
/usr/share/emacs/site-lisp/cedet/ede/ede hides /usr/share/emacs/24.3/lisp/cedet/ede
/usr/share/emacs/site-lisp/cedet/common/cedet-global hides /usr/share/emacs/24.3/lisp/cedet/cedet-global
/usr/share/emacs/site-lisp/cedet/common/mode-local hides /usr/share/emacs/24.3/lisp/cedet/mode-local
/usr/share/emacs/site-lisp/cedet/common/cedet hides /usr/share/emacs/24.3/lisp/cedet/cedet
/usr/share/emacs/site-lisp/cedet/common/data-debug hides /usr/share/emacs/24.3/lisp/cedet/data-debug
/usr/share/emacs/site-lisp/cedet/common/cedet-idutils hides /usr/share/emacs/24.3/lisp/cedet/cedet-idutils
/usr/share/emacs/site-lisp/cedet/srecode/srecode hides /usr/share/emacs/24.3/lisp/cedet/srecode
/usr/share/emacs/site-lisp/cedet/common/cedet-cscope hides /usr/share/emacs/24.3/lisp/cedet/cedet-cscope
/usr/share/emacs/site-lisp/cedet/common/cedet-files hides /usr/share/emacs/24.3/lisp/cedet/cedet-files
/usr/share/emacs/site-lisp/cedet/common/inversion hides /usr/share/emacs/24.3/lisp/cedet/inversion

Features:
(shadow sort gnus-util mail-extr emacsbug message idna format-spec
rfc822 mml mml-sec mm-decode mm-bodies mm-encode mail-parse rfc2231
mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums
mm-util mail-prsvr mail-utils nxml-uchnm rng-xsd xsd-regexp rng-cmpct
rng-nxml rng-valid rng-loc rng-uri rng-parse nxml-parse rng-match rng-dt
rng-util rng-pttrn nxml-ns nxml-mode nxml-outln nxml-rap nxml-util
nxml-glyph nxml-enc xmltok sh-script smie executable term disp-table
ehelp electric ring misearch multi-isearch vc-git slim-mode help-mode
easymenu slim-mode-autoloads package time-date tooltip ediff-hook
vc-hooks lisp-float-type mwheel x-win x-dnd tool-bar dnd fontset image
regexp-opt fringe tabulated-list newcomment lisp-mode register page
menu-bar rfn-eshadow timer select scroll-bar mouse jit-lock font-lock
syntax facemenu font-core frame cham georgian utf-8-lang misc-lang
vietnamese tibetan thai tai-viet lao korean japanese hebrew greek
romanian slovak czech european ethiopic indian cyrillic chinese
case-table epa-hook jka-cmpr-hook help simple abbrev minibuffer loaddefs
button faces cus-face macroexp files text-properties overlay sha1 md5
base64 format env code-pages mule custom widget hashtable-print-readable
backquote make-network-process dbusbind dynamic-setting
system-font-setting font-render-setting move-toolbar gtk x-toolkit x
multi-tty emacs)





^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#14324: 24.3; GTK scrollbar doesn't scroll proportionally when Line Wrapping is set to "Truncate Long Lines"
  2013-04-30 17:02 bug#14324: 24.3; GTK scrollbar doesn't scroll proportionally when Line Wrapping is set to "Truncate Long Lines" j.pertres
@ 2013-05-09 19:33 ` Stefan Monnier
  2021-05-31  6:03 ` Lars Ingebrigtsen
  1 sibling, 0 replies; 11+ messages in thread
From: Stefan Monnier @ 2013-05-09 19:33 UTC (permalink / raw)
  To: j.pertres; +Cc: 14324

>   1. Visit a buffer with very long lines, and long enough to make
>   Emacs render a vertical scrollbar.
>   2. In the Options menu, set the option "Line Wrapping" to "Truncate
>   Long Lines".
>   3. Drag the scrollbar to navigate the file.  Emacs won't scroll
>   proportionally, but rather get stuck at some points, seemingly at
>   those very long lines, maybe as if they were still shown in multiple
>   lines, even though now they don't.

Indeed.  The scrollbar's thumb is placed based on character positions in
the buffer, which is used as an approximation for the "pixel position"
on the rendering of the buffer.

There are various circumstances where this approximation is poor,
basically when some part of the buffer has a visual size that is
disconnected from its character size, e.g. when you use something like
outline-minor-mode, or when you have (large) images in the buffer, or
when (very long) lines are truncated.

I don't see any easy way to fix it.  I fear fixing it would require
a complete redesign of the rendering engine.

We could probably "fix" your case by adding a line-cache, such that
the scrollbar thumb's position can be computed based on line positions
rather than char positions when lines are truncated.  Patch welcome.


        Stefan





^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#14324: 24.3; GTK scrollbar doesn't scroll proportionally when Line Wrapping is set to "Truncate Long Lines"
  2013-04-30 17:02 bug#14324: 24.3; GTK scrollbar doesn't scroll proportionally when Line Wrapping is set to "Truncate Long Lines" j.pertres
  2013-05-09 19:33 ` Stefan Monnier
@ 2021-05-31  6:03 ` Lars Ingebrigtsen
  2021-05-31 15:28   ` Eli Zaretskii
  1 sibling, 1 reply; 11+ messages in thread
From: Lars Ingebrigtsen @ 2021-05-31  6:03 UTC (permalink / raw)
  To: j.pertres; +Cc: 14324

j.pertres@gmail.com writes:

> To reproduce:
>   1. Visit a buffer with very long lines, and long enough to make Emacs render a
>   vertical scrollbar
>   2. In the Options menu, set the option "Line Wrapping" to "Truncate
>   Long Lines"
>   3. Drag the scrollbar to navigate the file. Emacs won't scroll
>   proportionally, but rather get stuck at some points, seemingly at
>   those very long lines, maybe as if they were still shown in multiple
>   lines, even though now they don't.

I can confirm that this problem is still present in Emacs 28.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#14324: 24.3; GTK scrollbar doesn't scroll proportionally when Line Wrapping is set to "Truncate Long Lines"
  2021-05-31  6:03 ` Lars Ingebrigtsen
@ 2021-05-31 15:28   ` Eli Zaretskii
  2021-06-01  5:59     ` Lars Ingebrigtsen
  0 siblings, 1 reply; 11+ messages in thread
From: Eli Zaretskii @ 2021-05-31 15:28 UTC (permalink / raw)
  To: Lars Ingebrigtsen; +Cc: j.pertres, 14324

> From: Lars Ingebrigtsen <larsi@gnus.org>
> Date: Mon, 31 May 2021 08:03:42 +0200
> Cc: 14324@debbugs.gnu.org
> 
> j.pertres@gmail.com writes:
> 
> > To reproduce:
> >   1. Visit a buffer with very long lines, and long enough to make Emacs render a
> >   vertical scrollbar
> >   2. In the Options menu, set the option "Line Wrapping" to "Truncate
> >   Long Lines"
> >   3. Drag the scrollbar to navigate the file. Emacs won't scroll
> >   proportionally, but rather get stuck at some points, seemingly at
> >   those very long lines, maybe as if they were still shown in multiple
> >   lines, even though now they don't.
> 
> I can confirm that this problem is still present in Emacs 28.

Which file did you use for testing this?





^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#14324: 24.3; GTK scrollbar doesn't scroll proportionally when Line Wrapping is set to "Truncate Long Lines"
  2021-05-31 15:28   ` Eli Zaretskii
@ 2021-06-01  5:59     ` Lars Ingebrigtsen
  2021-06-01 12:28       ` Eli Zaretskii
  0 siblings, 1 reply; 11+ messages in thread
From: Lars Ingebrigtsen @ 2021-06-01  5:59 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: j.pertres, 14324

[-- Attachment #1: Type: text/plain, Size: 308 bytes --]

Eli Zaretskii <eliz@gnu.org> writes:

>> I can confirm that this problem is still present in Emacs 28.
>
> Which file did you use for testing this?

Included below -- I just pasted a bunch of long lines.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no

[-- Attachment #2: longlines.txt --]
[-- Type: text/plain, Size: 2283 bytes --]

1. Visit a buffer with very long lines, and long enough to make Emacs render a 1. Visit a buffer with very long lines, and long enough to make Emacs render a 1. Visit a buffer with very long lines, and long enough to make Emacs render a 1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a

1. Visit a buffer with very long lines, and long enough to make Emacs render a

1. Visit a buffer with very long lines, and long enough to make Emacs render a

1. Visit a buffer with very long lines, and long enough to make Emacs render a

1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a1. Visit a buffer with very long lines, and long enough to make Emacs render a

^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#14324: 24.3; GTK scrollbar doesn't scroll proportionally when Line Wrapping is set to "Truncate Long Lines"
  2021-06-01  5:59     ` Lars Ingebrigtsen
@ 2021-06-01 12:28       ` Eli Zaretskii
  2021-06-02  5:23         ` Lars Ingebrigtsen
  0 siblings, 1 reply; 11+ messages in thread
From: Eli Zaretskii @ 2021-06-01 12:28 UTC (permalink / raw)
  To: Lars Ingebrigtsen; +Cc: j.pertres, 14324

> From: Lars Ingebrigtsen <larsi@gnus.org>
> Cc: j.pertres@gmail.com,  14324@debbugs.gnu.org
> Date: Tue, 01 Jun 2021 07:59:05 +0200
> 
> >> I can confirm that this problem is still present in Emacs 28.
> >
> > Which file did you use for testing this?
> 
> Included below -- I just pasted a bunch of long lines.

Thanks.  I don't see any issues with this.  I'm not on GTK, so maybe
this is an issue with GTK scrollbars?  What happens if you customize
the value of scroll-bar-adjust-thumb-portion?





^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#14324: 24.3; GTK scrollbar doesn't scroll proportionally when Line Wrapping is set to "Truncate Long Lines"
  2021-06-01 12:28       ` Eli Zaretskii
@ 2021-06-02  5:23         ` Lars Ingebrigtsen
  2021-06-02 12:10           ` Eli Zaretskii
  0 siblings, 1 reply; 11+ messages in thread
From: Lars Ingebrigtsen @ 2021-06-02  5:23 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: j.pertres, 14324

[-- Attachment #1: Type: text/plain, Size: 220 bytes --]

Eli Zaretskii <eliz@gnu.org> writes:

> Thanks.  I don't see any issues with this.  I'm not on GTK, so maybe
> this is an issue with GTK scrollbars?

Just so we're on the same page, here's screenshots of the situation.


[-- Attachment #2: long1.jpg --]
[-- Type: image/jpeg, Size: 224823 bytes --]

[-- Attachment #3: Type: text/plain, Size: 34 bytes --]


This is without truncate-lines.


[-- Attachment #4: long2.jpg --]
[-- Type: image/jpeg, Size: 56783 bytes --]

[-- Attachment #5: Type: text/plain, Size: 80 bytes --]


With truncate-lines.  Note that the scroll bar has the same identical
length.


[-- Attachment #6: long3.jpg --]
[-- Type: image/jpeg, Size: 57206 bytes --]

[-- Attachment #7: Type: text/plain, Size: 533 bytes --]


And finally with the lines truncated for real -- note the longer scroll
bar.

So it seems to compute the length of the scroll bar based on the
non-truncated length of the text in the buffer.

> What happens if you customize the value of
> scroll-bar-adjust-thumb-portion?

Then it seems to adjust the height of the scroll bar logically (i.e.,
based on what's shown in the window, and not on the length of the
(truncated) text).

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no

^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#14324: 24.3; GTK scrollbar doesn't scroll proportionally when Line Wrapping is set to "Truncate Long Lines"
  2021-06-02  5:23         ` Lars Ingebrigtsen
@ 2021-06-02 12:10           ` Eli Zaretskii
  2021-06-03  7:12             ` Lars Ingebrigtsen
  0 siblings, 1 reply; 11+ messages in thread
From: Eli Zaretskii @ 2021-06-02 12:10 UTC (permalink / raw)
  To: Lars Ingebrigtsen; +Cc: j.pertres, 14324

> From: Lars Ingebrigtsen <larsi@gnus.org>
> Cc: j.pertres@gmail.com,  14324@debbugs.gnu.org
> Date: Wed, 02 Jun 2021 07:23:10 +0200
> 
> With truncate-lines.  Note that the scroll bar has the same identical
> length.

I think this is a known problem, since we don't count screen lines, we
count characters.

> > What happens if you customize the value of
> > scroll-bar-adjust-thumb-portion?
> 
> Then it seems to adjust the height of the scroll bar logically (i.e.,
> based on what's shown in the window, and not on the length of the
> (truncated) text).

So does it mean that that variable could be a solution to the problem?
Or did I misunderstand you?





^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#14324: 24.3; GTK scrollbar doesn't scroll proportionally when Line Wrapping is set to "Truncate Long Lines"
  2021-06-02 12:10           ` Eli Zaretskii
@ 2021-06-03  7:12             ` Lars Ingebrigtsen
  2021-06-03  8:01               ` Eli Zaretskii
  0 siblings, 1 reply; 11+ messages in thread
From: Lars Ingebrigtsen @ 2021-06-03  7:12 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: j.pertres, 14324

Eli Zaretskii <eliz@gnu.org> writes:

>> > What happens if you customize the value of
>> > scroll-bar-adjust-thumb-portion?
>> 
>> Then it seems to adjust the height of the scroll bar logically (i.e.,
>> based on what's shown in the window, and not on the length of the
>> (truncated) text).
>
> So does it mean that that variable could be a solution to the problem?
> Or did I misunderstand you?

The bug reported by the user is that Emacs miscalculates the size of the
scroll bar by default (with truncated lines).  It doesn't miscalculate
this if `scroll-bar-adjust-thumb-portion' is nil, so it seems like this
is a bug that could (and should) be fixed in the t case.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#14324: 24.3; GTK scrollbar doesn't scroll proportionally when Line Wrapping is set to "Truncate Long Lines"
  2021-06-03  7:12             ` Lars Ingebrigtsen
@ 2021-06-03  8:01               ` Eli Zaretskii
  2021-06-03  8:11                 ` Lars Ingebrigtsen
  0 siblings, 1 reply; 11+ messages in thread
From: Eli Zaretskii @ 2021-06-03  8:01 UTC (permalink / raw)
  To: Lars Ingebrigtsen; +Cc: j.pertres, 14324

> From: Lars Ingebrigtsen <larsi@gnus.org>
> Cc: j.pertres@gmail.com,  14324@debbugs.gnu.org
> Date: Thu, 03 Jun 2021 09:12:28 +0200
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> > So does it mean that that variable could be a solution to the problem?
> > Or did I misunderstand you?
> 
> The bug reported by the user is that Emacs miscalculates the size of the
> scroll bar by default (with truncated lines).  It doesn't miscalculate
> this if `scroll-bar-adjust-thumb-portion' is nil, so it seems like this
> is a bug that could (and should) be fixed in the t case.

This bug is about Emacs getting "stuck" while scrolling, or scrolling
erratically, not about miscalculation of the thumb size, right?

I may be misremembering, but AFAIR that variable was introduced
because some people actually _like_ the current default behavior wrt
calculating the size of the scroll-bar thumb.

Emacs should not get stuck scrolling, of course, but I cannot
reproduce that on my system, so someone will have to investigate and
tell why scrolling gets stuck or scrolls erratically in some
situations when scroll-bar-adjust-thumb-portion is non-nil.  Or maybe
I misunderstand what erratic scrolling is being alluded to here.





^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#14324: 24.3; GTK scrollbar doesn't scroll proportionally when Line Wrapping is set to "Truncate Long Lines"
  2021-06-03  8:01               ` Eli Zaretskii
@ 2021-06-03  8:11                 ` Lars Ingebrigtsen
  0 siblings, 0 replies; 11+ messages in thread
From: Lars Ingebrigtsen @ 2021-06-03  8:11 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: j.pertres, 14324

Eli Zaretskii <eliz@gnu.org> writes:

> This bug is about Emacs getting "stuck" while scrolling, or scrolling
> erratically, not about miscalculation of the thumb size, right?

I interpreted "stuck" as "the scrollbar isn't moving" (or moving
erratically), but perhaps it's about really getting stuck?  Perhaps the
original bug reporter can clarify.

> I may be misremembering, but AFAIR that variable was introduced
> because some people actually _like_ the current default behavior wrt
> calculating the size of the scroll-bar thumb.

Sure, I can see somebody preferring the current behaviour (since it
reflects the actual buffer contents and not the visual contents).  But
in that case, both nil and t cases of `scroll-bar-adjust-thumb-portion'
should support visual/non-visual scroll bar lengths, perhaps?

(Because `scroll-bar-adjust-thumb-portion' is just about adjusting the
size so that you can always overscroll, according to the doc string.)

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2021-06-03  8:11 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-04-30 17:02 bug#14324: 24.3; GTK scrollbar doesn't scroll proportionally when Line Wrapping is set to "Truncate Long Lines" j.pertres
2013-05-09 19:33 ` Stefan Monnier
2021-05-31  6:03 ` Lars Ingebrigtsen
2021-05-31 15:28   ` Eli Zaretskii
2021-06-01  5:59     ` Lars Ingebrigtsen
2021-06-01 12:28       ` Eli Zaretskii
2021-06-02  5:23         ` Lars Ingebrigtsen
2021-06-02 12:10           ` Eli Zaretskii
2021-06-03  7:12             ` Lars Ingebrigtsen
2021-06-03  8:01               ` Eli Zaretskii
2021-06-03  8:11                 ` Lars Ingebrigtsen

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).