[Top][All Lists]

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

RE: mwheel scroll horizontally

From: Stephen J. Turnbull
Subject: RE: mwheel scroll horizontally
Date: Tue, 05 Oct 2010 13:29:53 +0900

Drew Adams writes:

 > And, as always, we should make it clear that such bindings of the wheel to
 > scrolling actions are only a convenience (default behavior) and the user and
 > 3rd-party libraries are free to bind the wheel to any other commands, 
 > anywhere.

That's not "as always".  In general, there are strict policies about
who may bind what, with C-c <letter> reserved to the user, C-c
<punctuation> allocated to minor modes (IIRC), and "everything else"
allocated to the global map (ie, Rule by Bikeshed on Emacs Devel).

Major modes may bind anything, of course, but ISTM that many of the
desirable behaviors described here are likely to fit minor modes
("useful in various contexts") rather than major modes ("specific
applications").  So AIUI mouse bindings *currently* are (by default
and apparently without too much thought put into the matter) part of
the global map.

I agree with you that there *should* be a thought out policy for mouse
gestures.  There are fewer of them and they are less arbitrary than
keystrokes, so the allocation will be different from keys.  I think a
reasonable policy would be to allocate:

1.  Unmodified mouse gestures to the global map; these should be
    consistent with the platform standards by default, but there
    should be emulation minor modes so that multiplatform users can
    have a consistent environment (eg, on Mac OS X by default you drag
    to select text, then drag and drop that selection to copy it; but
    it should be easy to invoke an X emulation mode where you drag to
    select text, then middle click to insert the selection at the
    mouse cursor).

2.  One modifier to be reserved to the user (eg, C-<mouse gesture>
    should never be bound by Emacs or any library -- of course, which
    modifier is open to bikeshedding, er, discussion).

3.  One modifier reserved for use of the current major mode (eg,
    Shift-<mouse gesture>; same bikeshedding caveat).

4.  The remaining <modifier>-<mouse gesture>s may be bound by minor
    modes, and for most such modes the user should be able to
    configure the mouse modifier used by the minor mode.

I'm not a big rodent rider, so the concrete suggestions above should
be taken with a grain of salt.  Maybe the framework is useful, though.

reply via email to

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