emacs-devel
[Top][All Lists]
Advanced

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

Re: [PATCH] Improve interaction between mouse-drag-region and scroll-mar


From: Yuri D'Elia
Subject: Re: [PATCH] Improve interaction between mouse-drag-region and scroll-margin
Date: Sat, 25 Sep 2021 18:31:40 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

On Sat, Sep 25 2021, Eli Zaretskii wrote:
>> auto-hscroll-mode in mouse-drag-region and do not re-enable them until
>> dragging is over, making selections work as expected when inside the
>> margins.
>
> If you disable auto-hscroll-mode, why do you also need to zero out
> hscroll-margin?

It doesn't, it just disables auto-hscroll-mode. Maybe I should reword
the commit.

>> +    ;; Suppress automatic scrolling near the edges while tracking
>> +    ;; movement, as it interferes with the natural dragging behavior
>> +    ;; (point will unexpectedly be moved beneath the pointer, making
>> +    ;; selections in auto-scrolling margins impossible).
>> +    (setq auto-hscroll-mode nil)
>> +    (setq scroll-margin 0)
>
> Shouldn't this be in unwind-protect?

I guess, yes.

There's probably more side-effect that would be need to be
taken-care of inside that big let* (looking at that mouse-set-point...).

> And I think this also warrants a NEWS entry.

Ok




reply via email to

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