[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: when to bind *down-mouse* vs *mouse*?
From: |
Luc Teirlinck |
Subject: |
Re: when to bind *down-mouse* vs *mouse*? |
Date: |
Sat, 4 Dec 2004 18:10:05 -0600 (CST) |
Lennart Borgman wrote:
My impression of this "standard" is that it is good because you do not have
to use the mouse very much, which can be difficult for some people and for
some other is an unnecessary burden and a hazard. I believe that this could
be a reason for the choice MS has made here.
As Jan already pointed out, the current behavior is standard on X and
has its advantages. I believe it is important that users can do
everything in Emacs without the mouse, if that is what they either
choose or have to do. The "MS standard" is not mouse-independent
either. The Font Menu and much of Enriched mode rely on the <f10>
mouse-less menubar access to enable users to get by without the
mouse. This is not ideal, but better than nothing.
In the case of access to the Font Menu, we have a bug however:
Do:
emacs -q
<f10> o f
Result:
byte-code: Wrong type argument: listp, 102
102 is the character code for `f'.
The patch below fixes this. Note that, in addition to fixing the bug,
it seems to point out a problem with the `x-popup-menu' docstring
which says:
x-popup-menu is a built-in function in `C source code'.
(x-popup-menu position menu)
Pop up a deck-of-cards menu and return user's selection.
position is a position specification. This is either a mouse button event
or a list ((XOFFSET YOFFSET) WINDOW)
where XOFFSET and YOFFSET are positions in pixels from the top left
corner of WINDOW's frame. (WINDOW may be a frame object instead of a window.)
This controls the position of the center of the first line
in the first pane of the menu, not the top left of the menu as a whole.
But applying the patch below, which uses (0 0) for (XOFFSET YOFFSET)
seems to show that it controls the position of the top left of the
menu as a whole, no matter how clearly this is denied above.
I can install the patch if desired.
===File ~/mouse.el-diff=====================================
*** mouse.el 12 Nov 2004 19:47:19 -0600 1.257
--- mouse.el 04 Dec 2004 17:35:29 -0600
***************
*** 2201,2207 ****
(progn (unless (display-multi-font-p)
(error "Cannot change fonts on this display"))
(x-popup-menu
! last-nonmenu-event
;; Append list of fontsets currently defined.
(append x-fixed-font-alist (list (generate-fontset-menu))))))
(if fonts
--- 2201,2209 ----
(progn (unless (display-multi-font-p)
(error "Cannot change fonts on this display"))
(x-popup-menu
! (if (listp last-nonmenu-event)
! last-nonmenu-event
! (list '(0 0) (selected-window)))
;; Append list of fontsets currently defined.
(append x-fixed-font-alist (list (generate-fontset-menu))))))
(if fonts
============================================================
- RE: when to bind *down-mouse* vs *mouse*?, (continued)
Re: when to bind *down-mouse* vs *mouse*?, Luc Teirlinck, 2004/12/02
- RE: when to bind *down-mouse* vs *mouse*?, Drew Adams, 2004/12/03
- Re: when to bind *down-mouse* vs *mouse*?, Luc Teirlinck, 2004/12/03
- Re: when to bind *down-mouse* vs *mouse*?, Jason Rumney, 2004/12/04
- Re: when to bind *down-mouse* vs *mouse*?, Alex Schroeder, 2004/12/04
- Re: when to bind *down-mouse* vs *mouse*?, Lennart Borgman, 2004/12/04
- Re: when to bind *down-mouse* vs *mouse*?, Jan D., 2004/12/04
- Re: when to bind *down-mouse* vs *mouse*?,
Luc Teirlinck <=
- Re: when to bind *down-mouse* vs *mouse*?, Jan D., 2004/12/07
RE: when to bind *down-mouse* vs *mouse*?, Drew Adams, 2004/12/06
Re: when to bind *down-mouse* vs *mouse*?, Stefan Monnier, 2004/12/06
Re: when to bind *down-mouse* vs *mouse*?, Alex Schroeder, 2004/12/07
RE: when to bind *down-mouse* vs *mouse*?, Drew Adams, 2004/12/08
Re: when to bind *down-mouse* vs *mouse*?, Stefan Monnier, 2004/12/08
RE: when to bind *down-mouse* vs *mouse*?, Drew Adams, 2004/12/08
Re: when to bind *down-mouse* vs *mouse*?, Richard Stallman, 2004/12/09