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

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

bug#35659: 26.1; Weird horizontal scroll behavior with certain settings


From: Clemens Radermacher
Subject: bug#35659: 26.1; Weird horizontal scroll behavior with certain settings for `auto-hscroll-mode' and `hscroll-step`.
Date: Fri, 10 May 2019 16:25:05 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1

> I think the fact that it happens for hscroll-step of zero is "by sheer
> luck".  I certainly don't remember explicitly coding that.

Programmers need luck, too ;)

> Maybe someone will find an easy fix, volunteers are welcome.  Emacs
> really shouldn't depend for its display code development on one old
> curmudgeon such as myself...

I had some success with this workaround (ugly but it's enough for my use case):

    (defun my-temporary-change-hscroll (f &rest args)
      (setq hscroll-step 0)
      (apply f args)
      (run-at-time 0.1 nil
                   (lambda ()
                     (setq hscroll-step 1))))

    (advice-add #'previous-line :around 'my-temporary-change-hscroll)
    (advice-add #'next-line :around 'my-temporary-change-hscroll)

I would really like to dig into it but I hardly know any C and I have read 
several times
that the Emacs code base is reserved for advanced C programmers. Thank you for 
all the work you are doing, Emacs is such a great software!

        Clemens





reply via email to

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