all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Stefan Monnier <monnier@iro.umontreal.ca>
To: Le Wang <l26wang@gmail.com>
Cc: 9541@debbugs.gnu.org
Subject: bug#9541: mouse-1 inside scroll-margin causes undesirable region activation
Date: Mon, 19 Sep 2011 14:34:36 -0400	[thread overview]
Message-ID: <jwvpqiwl75p.fsf-monnier+gnus-read-ephemeral-bug@gnu.org> (raw)
In-Reply-To: <CAM=K+ioo44quc__GYVom61MYfZJWMsNVve5yR-1YjsxBMEE0OA@mail.gmail.com> (Le Wang's message of "Sun, 18 Sep 2011 19:31:27 +0800")

> Here is my work-around.  I don't fully understand the ramifications of
> doing this, but so far it seems work.

> (defun le::mouse-drag-region (event)
>   "mouse-drag-region but clickable in scroll-margin"
>   (interactive "e")
>   (let ((scroll-margin 0))
>     (mouse-drag-region event)))

But this goes against the definition of scroll-margin which does not
make any exception for mouse events.

An alternative would be to declare that scroll-margin does not apply to
commands when run via mouse events.

This said, the current behavior of scroll-margin is clearly problematic
and even buggy (e.g. it seems that displaying the EOB prevents the
mouse-clicks from causing a scroll, even when that scroll would be
towards the BOB).


        Stefan





  reply	other threads:[~2011-09-19 18:34 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-18  9:14 bug#9541: mouse-1 inside scroll-margin causes undesirable region activation Le Wang
     [not found] ` <handler.9541.B.131633755619433.ack@debbugs.gnu.org>
2011-09-18 11:31   ` bug#9541: Acknowledgement (mouse-1 inside scroll-margin causes undesirable region activation) Le Wang
2011-09-19 18:34     ` Stefan Monnier [this message]
2011-09-23 20:52       ` bug#9541: mouse-1 inside scroll-margin causes undesirable region activation Johan Bockgård
2011-09-24 18:38         ` Chong Yidong
2011-10-02 10:03           ` New mouse click behavior (was: bug#9541: mouse-1 inside scroll-margin causes undesirable region activation) Johan Bockgård
2011-10-02 12:14             ` New mouse click behavior martin rudalics

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=jwvpqiwl75p.fsf-monnier+gnus-read-ephemeral-bug@gnu.org \
    --to=monnier@iro.umontreal.ca \
    --cc=9541@debbugs.gnu.org \
    --cc=l26wang@gmail.com \
    /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.