bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#46316: 27.1; wrong horizontal scroll with truncate-lines value t


From: Stefan Kangas
Subject: bug#46316: 27.1; wrong horizontal scroll with truncate-lines value t
Date: Fri, 9 Apr 2021 11:59:26 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

Eli Zaretskii <eliz@gnu.org> writes:

>> From: ynyaaa@gmail.com
>> Cc: 46316@debbugs.gnu.org
>> Date: Mon, 15 Feb 2021 00:43:32 +0900
>>
>> >> (let ((buf (generate-new-buffer "tmp")))
>> >>   (switch-to-buffer buf)
>> >>   (setq truncate-lines t)
>> >>   (dotimes (i 200)
>> >>     (insert (format ":%03d" i))
>> >>     (when (= 0 (% (1+ i) 100)) (insert ?\n)))
>> >>   (forward-char -1)
>> >>   (sit-for 1)
>> >>   (set-window-hscroll nil (window-hscroll))
>> >>   (save-excursion
>> >>     (forward-char -100)
>> >>     (insert-char ?\n 10)
>> >>     ))
>> >
>> > Sorry, I don't think I follow: what exactly is the bug here?  What did
>> > you expect to happen ,and what did actually happen?
>>
>> The expression '(set-window-hscroll nil (window-hscroll))' should not
>> have any effect
>
> That's not true: calling set-window-hscroll inhibits automatic
> hscrolling, until point moves for some reason.
>
>> but if it is deleted from the form, auto-hscroll-mode works
>> correctly.
>
> I think this is expected: the text your recipe adds is not around
> point, so we don't re-enable auto-hscroll.
>
>> Not only point motion but also buffer modification should be checked for
>> auto-hscroll-mode.
>
> If you want this to happen, don't call set-window-hscroll.

This was tagged notabug and Eli explained that the behavior is
expected.  The bug that was here has been fixed.

There also has been no further update within 7 weeks.

I'm therefore closing this bug report.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]