Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prevent scrolling during collection? #204

Open
noctuid opened this issue Dec 24, 2021 · 1 comment
Open

Prevent scrolling during collection? #204

noctuid opened this issue Dec 24, 2021 · 1 comment

Comments

@noctuid
Copy link
Owner

noctuid commented Dec 24, 2021

We do set scroll-margin to zero when placing the avy overlays, but we should maybe do something prevent scrolling/window movement during collection as well (related: #181). Not sure if there are situations where this will cause issues.

@madand
Copy link

madand commented Dec 26, 2021

In Customize buffers there is an issue with scrolling happening right after the candidates collection, if point is at the window end.

The scrolling may be triggered by the echo area growth. The echo area may grow because every link help text gets printed during candidate collection process. These messages also pollute the *Messages* buffer.

I wasn't able to figure out why the messages are printed; but I found a workaround to disable the minibuffer growth:

(defun my-with-inhibit-resize-mini-widows (function &rest arguments)
  "Call FUNCTION with ARGUMENTS, with `resize-mini-windows' bound to nil."
  (let ((resize-mini-windows nil))
    (apply function arguments)))
    
(advice-add 'link-hint-open-link :around #'my-with-inhibit-resize-mini-widows)
;; (advice-remove 'link-hint-open-link  #'my-with-inhibit-resize-mini-widows)

Here are some screenshots of the issue. The point is on the triangle glyph to the left from the text "Modus Themes Bold Constructs". Ah, and scroll-margin equals 1.

link-hint-before
link-hint-after

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants