Using flyspell in Emacs on Mac OS X

Using flyspell in Emacs on Mac OS X

Post by D. D. Brierto » Thu, 10 Jul 2003 07:27:55



I've been setting up Carbon Emacs (21.3.50.6) for a friend on her iBook
running Mac OS X 10.2.6, primarily for writing*in AUC-TeX. She
wanted to have spell-checking, so I installed both ispell and aspell and
various dictionaries. I also switched on flyspell by default for AUC-TeX.
However, I can see no way of using the mouse to popup the flyspell context
menu - in Linux I would do that by clicking with mouse-2 on a misspelled
word.

what do other Mac users do to get that working?

TIA, Darren

--
======================================================================

       Trying is the first step towards failure (Homer Simpson)
======================================================================

 
 
 

Using flyspell in Emacs on Mac OS X

Post by Eric Jacobon » Thu, 10 Jul 2003 08:12:55



Quote:> However, I can see no way of using the mouse to popup the flyspell
> context menu - in Linux I would do that by clicking with mouse-2 on
> a misspelled word.

> what do other Mac users do to get that working?

With Mac OS, i do exactly as with other Unix : clicking with the
middle button popup the flyspell context menu... and i've done
absolutely nothing special.

--
ric Jacoboni, n il y a 1361149882 secondes

 
 
 

Using flyspell in Emacs on Mac OS X

Post by D. D. Brierto » Thu, 10 Jul 2003 08:42:49



> With Mac OS, i do exactly as with other Unix : clicking with the
> middle button popup the flyspell context menu... and i've done
> absolutely nothing special.

Sorry, I wasn't clear enough. My friend is using an iBook *without*
external mouse, so she has only one mouse button on her trackpad. I either
need to find out how to simulate a mouse-2 click, or to add something to
her .emacs to allow mouse-1 to call up the flyspell context menu.

Best, Darren

--
======================================================================

       Trying is the first step towards failure (Homer Simpson)
======================================================================

 
 
 

Using flyspell in Emacs on Mac OS X

Post by Eric Jacobon » Thu, 10 Jul 2003 15:19:22



Quote:> Sorry, I wasn't clear enough. My friend is using an iBook *without*
> external mouse, so she has only one mouse button on her trackpad. I either
> need to find out how to simulate a mouse-2 click, or to add something to
> her .emacs to allow mouse-1 to call up the flyspell context menu.

Well, i suppose it's possible to emulate a mouse-2 click with some Alt
or Ctrl click combinaison or by tweaking the .emacs file but,
honestly, a good three buttons mouse is not that expensive and much
more productive from my point of view.

--
ric Jacoboni, n il y a 1361175417 secondes

 
 
 

Using flyspell in Emacs on Mac OS X

Post by D. D. Brierto » Thu, 10 Jul 2003 17:52:58



> Well, i suppose it's possible to emulate a mouse-2 click with some Alt
> or Ctrl click combinaison or by tweaking the .emacs file but,
> honestly, a good three buttons mouse is not that expensive and much
> more productive from my point of view.

In general that's true, but due to her circumstances probably not feasible
(she has to travel a lot and spends lots of time working in airports,
planes and trains where the laptop really is a lap top).

--
======================================================================

       Trying is the first step towards failure (Homer Simpson)
======================================================================

 
 
 

Using flyspell in Emacs on Mac OS X

Post by Piet van Oostru » Sat, 12 Jul 2003 18:24:47



Quote:>> With Mac OS, i do exactly as with other Unix : clicking with the
>> middle button popup the flyspell context menu... and i've done
>> absolutely nothing special.

DDB> Sorry, I wasn't clear enough. My friend is using an iBook *without*
DDB> external mouse, so she has only one mouse button on her trackpad. I either
DDB> need to find out how to simulate a mouse-2 click, or to add something to
DDB> her .emacs to allow mouse-1 to call up the flyspell context menu.

I have a patch for Emacs on Mac OS X to emulate a three button mouse with
Option and Command. I am just testing it.
--

URL: http://www.cs.uu.nl/~piet [PGP]

 
 
 

Using flyspell in Emacs on Mac OS X

Post by Pierre Gasto » Sat, 12 Jul 2003 20:58:54




> > With Mac OS, i do exactly as with other Unix : clicking with the
> > middle button popup the flyspell context menu... and i've done
> > absolutely nothing special.

> Sorry, I wasn't clear enough. My friend is using an iBook *without*
> external mouse, so she has only one mouse button on her trackpad. I either
> need to find out how to simulate a mouse-2 click, or to add something to
> her .emacs to allow mouse-1 to call up the flyspell context menu.

> Best, Darren

hi,

Here is a quick function to emulate the middle button (emacs)

(defun middle-click (click &optional arg)
  (interactive "e\nP")
  (let ((event (event-start click)))
    ;; handle error if the function doesn't use the prefix
    (condition-case nil
        (funcall (key-binding (vector (list 'mouse-2 event))) click arg)
      (error (funcall (key-binding (vector (list 'mouse-2 event))) click)))))

;S-mouse-3 behave like mouse-2
(global-set-key [(S-mouse-3)] 'middle-click)

 
 
 

Using flyspell in Emacs on Mac OS X

Post by Kevin Rodger » Sun, 13 Jul 2003 02:18:09



> (defun middle-click (click &optional arg)
>   (interactive "e\nP")
>   (let ((event (event-start click)))
>     ;; handle error if the function doesn't use the prefix
>     (condition-case nil
>    (funcall (key-binding (vector (list 'mouse-2 event))) click arg)
>       (error (funcall (key-binding (vector (list 'mouse-2 event))) click)))))

Can that be simplified to:

(defun middle-click (click)
   (interactive "e")
   (let ((event (event-start click))
        (prefix-arg current-prefix-arg))
     (call-interactively (key-binding (vector (list 'mouse-2 event)) t))))

--
Kevin Rodgers

 
 
 

1. Mac OS X, using function keys in emacs

more an OS X (pronounced eks) question:

how to get the Mac OS X's terminal program to not intercept the
fuction keys, so that i can use the functions keys i have defined in
my emacs init file?

Similarly for the page up/down and numerical keypad keys. I want them
sent to emacs.

Also, how can one remap so that the command key is the meta key. (the
terminal preference only allow option/alt key as meta)

PS i haven't spent much time on this, but is there an mailing list or
newsgroup of OS X geared for unix sys admins?

 Xah

 http://xahlee.org/PageTwo_dir/more.html

2. Worth Waiting for Palm III X?

3. mac (os x) emacs: "fixed" fonts?

4. Wide-screen Scanners

5. mac (os x) emacs: browse-url and command-click for web links?

6. AutoCAD 2000 Upgrade Guide

7. Binding option key to meta, Emacs 21.1.1, Mac OS X

8. Problem with Javadoc comment on emacs 21.3.50.1 (Mac OS X)

9. Problem installing emacs 21 for Mac OS X

10. Mac OS X Patch for Emacs 21.1

11. Is there an emacs for Mac OS that works?

12. Emacs for the Mac OS?