From: Yuri D'Elia <wavexx@thregr.org>
To: emacs-devel@gnu.org
Subject: Re: [PATCH] Improve interaction between mouse-drag-region and scroll-margin
Date: Sat, 25 Sep 2021 18:31:40 +0200 [thread overview]
Message-ID: <875yuozker.fsf@wavexx.thregr.org> (raw)
In-Reply-To: 83zgs0pr3i.fsf@gnu.org
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
next prev parent reply other threads:[~2021-09-25 16:31 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-09-25 16:09 [PATCH] Improve interaction between mouse-drag-region and scroll-margin Yuri D'Elia
2021-09-25 16:17 ` Eli Zaretskii
2021-09-25 16:31 ` Yuri D'Elia [this message]
2021-09-25 16:41 ` Eli Zaretskii
2021-09-25 17:03 ` Yuri D'Elia
2021-09-25 17:19 ` Eli Zaretskii
2021-09-25 17:31 ` Yuri D'Elia
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=875yuozker.fsf@wavexx.thregr.org \
--to=wavexx@thregr.org \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.