There is the hook variable window-scroll-functions for functions to be called before redisplay after vertical scrolling.

Is there a similar variable for horizontal scrolling?

  • I access this information from within C when working on my own feature requests, but I don't think there is a hook available to the end user. You may wish to look at things such as w->hscroll (greater than zero when scrolling) and w->suspend_auto_hscroll and the value of auto-hscroll-mode. Keep in mind that there is also a feature of horizontal scrolling of the current line in recent versions of Emacs – lawlist Dec 8 '17 at 2:13
  • I don't find anything for this. And horizontal scrolling (e.g. C-<) is defined in C. So I'm guessing there is nothing for this. You might want to file an enhancement request (M-x report-emacs-bug). – Drew May 6 '18 at 0:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.