unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* Aspell and Emacs
@ 2004-01-28  3:06 Chris Swoyer
  2004-01-28 21:50 ` Martin Stemplinger
  2004-01-28 23:18 ` Bruce Ingalls
  0 siblings, 2 replies; 12+ messages in thread
From: Chris Swoyer @ 2004-01-28  3:06 UTC (permalink / raw)


I just downloaded and installed cocoAspell 1.4.1. I am using
enhanced carbon emacs (under Mac's OS 10.3.2).

1. what do I need to insert in my .emacs file so Emacs will use
    Aspell (when I installed things I moved a file called
    Spelling.prefPane to the  "PreferencePanes" subfolder of
    /Library -- but it didn't yield a file named Aspell or the
    like.

  2. Do I need to add anything to get Aspell to work from the
    command menu for LaTeX (at present I have the following line,
    which came with the set-up:


  (list "Spell" "<ignored>" 'TeX-run-ispell-on-document nil nil)

---

Thanks,
CS

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Aspell and Emacs
  2004-01-28  3:06 Aspell and Emacs Chris Swoyer
@ 2004-01-28 21:50 ` Martin Stemplinger
  2004-01-28 22:46   ` Chris Swoyer
  2004-01-28 23:18 ` Bruce Ingalls
  1 sibling, 1 reply; 12+ messages in thread
From: Martin Stemplinger @ 2004-01-28 21:50 UTC (permalink / raw)


On Mit Jan 28 2004 at 04:06, "Chris Swoyer" <fswoyer@cox.net> wrote:

> I just downloaded and installed cocoAspell 1.4.1. I am using
> enhanced carbon emacs (under Mac's OS 10.3.2).
>
> 1. what do I need to insert in my .emacs file so Emacs will use
>     Aspell (when I installed things I moved a file called
>     Spelling.prefPane to the  "PreferencePanes" subfolder of
>     /Library -- but it didn't yield a file named Aspell or the
>     like.
I don't use Mac, but the following lines in my .emacs work well both
on Windows and on Linux:
;;; Spelling
(setq ispell-program-name "aspell")
(autoload 'flyspell-mode "flyspell" "On-the-fly spelling." t)
(require 'ispell)
 
HTH
Martin
-- 
Remove NOSPAM to reply by mail

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Aspell and Emacs
  2004-01-28 21:50 ` Martin Stemplinger
@ 2004-01-28 22:46   ` Chris Swoyer
  2004-01-29  1:35     ` Tim McNamara
  0 siblings, 1 reply; 12+ messages in thread
From: Chris Swoyer @ 2004-01-28 22:46 UTC (permalink / raw)


Thanks, Emacs needs to know where the aspell program is,
and when I installed it I don't seem to have ended up with
an application named aspell. So I need to get something
in a workable path and then tell Emacs what the path is.

Chris


"Martin Stemplinger" <mstemplingerNOSPAM@gmx.de> wrote in message
news:m3smhzg2tv.fsf@ID-177771.users.individual.de...
> On Mit Jan 28 2004 at 04:06, "Chris Swoyer" <fswoyer@cox.net> wrote:
>
> > I just downloaded and installed cocoAspell 1.4.1. I am using
> > enhanced carbon emacs (under Mac's OS 10.3.2).
> >
> > 1. what do I need to insert in my .emacs file so Emacs will use
> >     Aspell (when I installed things I moved a file called
> >     Spelling.prefPane to the  "PreferencePanes" subfolder of
> >     /Library -- but it didn't yield a file named Aspell or the
> >     like.
> I don't use Mac, but the following lines in my .emacs work well both
> on Windows and on Linux:
> ;;; Spelling
> (setq ispell-program-name "aspell")
> (autoload 'flyspell-mode "flyspell" "On-the-fly spelling." t)
> (require 'ispell)
>
> HTH
> Martin
> -- 
> Remove NOSPAM to reply by mail

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Aspell and Emacs
  2004-01-28  3:06 Aspell and Emacs Chris Swoyer
  2004-01-28 21:50 ` Martin Stemplinger
@ 2004-01-28 23:18 ` Bruce Ingalls
  2004-01-29  0:30   ` Chris Swoyer
  2004-01-29 20:17   ` Kevin Rodgers
  1 sibling, 2 replies; 12+ messages in thread
From: Bruce Ingalls @ 2004-01-28 23:18 UTC (permalink / raw)


Chris Swoyer wrote:
> I just downloaded and installed cocoAspell 1.4.1. I am using
> enhanced carbon emacs (under Mac's OS 10.3.2).
> 
> 1. what do I need to insert in my .emacs file so Emacs will use
>     Aspell
  ...
Are you using Fink? I added the following contribution recently to
<url: http://emacro.sf.net/ > for Mac users.

Hmm. I bet I can change the first line to simply
	(when (file-readable-p "/sw/bin")
as well as drop the defun declaration...

;;__________________________________________________________________________
;;;;		Fink Paths
(when (and (file-readable-p "/sw/bin") (file-exists-p "/sw/sbin"))
   (defvar shell-bin-path
     '("/sw/bin" "/sw/sbin")
     "The paths where fink binaries can be found")

   (defun fix-shell-paths nil
     (if (and (boundp 'exec-path) (listp exec-path))
	(setq exec-path (append shell-bin-path exec-path))
       (setq exec-path shell-bin-path)))

   (fix-shell-paths))

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Aspell and Emacs
  2004-01-28 23:18 ` Bruce Ingalls
@ 2004-01-29  0:30   ` Chris Swoyer
  2004-01-29 20:17   ` Kevin Rodgers
  1 sibling, 0 replies; 12+ messages in thread
From: Chris Swoyer @ 2004-01-29  0:30 UTC (permalink / raw)


I'm not using fink (everything I have came via i-Installer + Emacs +
TexShop. It would
be nice to solve this with just these, but if fink is a good way to do so,
I'll give it
a shot.

Many thanks,
Chris


"Bruce Ingalls" <bingalls@fit-zones.NO-SPAM.com> wrote in message
news:DrXRb.276612$0P1.80114@twister.nyc.rr.com...
> Chris Swoyer wrote:
> > I just downloaded and installed cocoAspell 1.4.1. I am using
> > enhanced carbon emacs (under Mac's OS 10.3.2).
> >
> > 1. what do I need to insert in my .emacs file so Emacs will use
> >     Aspell
>   ...
> Are you using Fink? I added the following contribution recently to
> <url: http://emacro.sf.net/ > for Mac users.
>
> Hmm. I bet I can change the first line to simply
> (when (file-readable-p "/sw/bin")
> as well as drop the defun declaration...
>
>
;;__________________________________________________________________________
> ;;;; Fink Paths
> (when (and (file-readable-p "/sw/bin") (file-exists-p "/sw/sbin"))
>    (defvar shell-bin-path
>      '("/sw/bin" "/sw/sbin")
>      "The paths where fink binaries can be found")
>
>    (defun fix-shell-paths nil
>      (if (and (boundp 'exec-path) (listp exec-path))
> (setq exec-path (append shell-bin-path exec-path))
>        (setq exec-path shell-bin-path)))
>
>    (fix-shell-paths))

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Aspell and Emacs
  2004-01-28 22:46   ` Chris Swoyer
@ 2004-01-29  1:35     ` Tim McNamara
  0 siblings, 0 replies; 12+ messages in thread
From: Tim McNamara @ 2004-01-29  1:35 UTC (permalink / raw)


"Chris Swoyer" <fswoyer@cox.net> writes:

> Thanks, Emacs needs to know where the aspell program is, and when I
> installed it I don't seem to have ended up with an application named
> aspell. So I need to get something in a workable path and then tell
> Emacs what the path is.

Have you tried "which" in Terminal for ispell, aspell and
cocoaspell?  ALso, the cocoAspell home page appears to suggest that
the application installs in ~/Library/Services or /Library/Services.
You could check there.

You should also be able to install the normal aspell and call it from
Emacs of any variety, Aqua or X11.

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Aspell and Emacs
  2004-01-28 23:18 ` Bruce Ingalls
  2004-01-29  0:30   ` Chris Swoyer
@ 2004-01-29 20:17   ` Kevin Rodgers
  1 sibling, 0 replies; 12+ messages in thread
From: Kevin Rodgers @ 2004-01-29 20:17 UTC (permalink / raw)


Bruce Ingalls wrote:

> Are you using Fink? I added the following contribution recently to
> <url: http://emacro.sf.net/ > for Mac users.
> 
> Hmm. I bet I can change the first line to simply
>     (when (file-readable-p "/sw/bin")


I suggest:

	(when (and (file-directory-p "/sw/bin") (file-readable-p "/sw/bin"))


> as well as drop the defun declaration...


Definitely.  And is there any situation in which exec-path is not bound or its
value is not a list?


> ;;__________________________________________________________________________ 
> 
> ;;;;        Fink Paths
> (when (and (file-readable-p "/sw/bin") (file-exists-p "/sw/sbin"))
>   (defvar shell-bin-path
>     '("/sw/bin" "/sw/sbin")
>     "The paths where fink binaries can be found")
> 
>   (defun fix-shell-paths nil
>     (if (and (boundp 'exec-path) (listp exec-path))
>     (setq exec-path (append shell-bin-path exec-path))
>       (setq exec-path shell-bin-path)))
> 
>   (fix-shell-paths))


-- 
Kevin Rodgers

^ permalink raw reply	[flat|nested] 12+ messages in thread

* aspell and emacs
@ 2004-12-31  9:28 Neon Absentius
  2004-12-31 10:31 ` Ehud Karni
  0 siblings, 1 reply; 12+ messages in thread
From: Neon Absentius @ 2004-12-31  9:28 UTC (permalink / raw)


Hello

I know that by setting 

(setq ispell-program-name "aspell")

emacs uses the aspell program instead of ispell. I don't know however
how to make emacs aware of a new dictionary. Specifically I just
installed the greek aspell dictionary and I have no idea how to 
make emacs aware of the fact. 

Any help and/or pointing to specific documentation will be greatly
appreciated.

-- 
Charity in capitalism is like urinating to extinguish a forest fire.
    -- Neon Absentius
absent a.in.cirle sdf period lonestar period org
SDF Public Access UNIX System - http://sdf.lonestar.org

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: aspell and emacs
  2004-12-31  9:28 aspell and emacs Neon Absentius
@ 2004-12-31 10:31 ` Ehud Karni
  2004-12-31 22:43   ` Neon Absentius
  0 siblings, 1 reply; 12+ messages in thread
From: Ehud Karni @ 2004-12-31 10:31 UTC (permalink / raw)
  Cc: help-gnu-emacs

On Fri, 31 Dec 2004 09:28:53 +0000, Neon Absentius <absent@sdf.lonestar.org> wrote:
>
> (setq ispell-program-name "aspell")
>
> emacs uses the aspell program instead of ispell. I don't know however
> how to make emacs aware of a new dictionary. Specifically I just
> installed the greek aspell dictionary and I have no idea how to
> make emacs aware of the fact.

You should read the help for variables `ispell-dictionary-alist',
`ispell-dictionary' `ispell-local-dictionary' and the function
`(ispell-change-dictionary'. You may also need to set
`emacs.pane.menubar.font' and `emacs.menu.popup.font' in your
.Xdefaults to a font that can display greek letters.

An example for how to set the it to use the Hebrew dictionary is:

    (require 'ispell)

    ;; Tell emacs what constitutes a word.
    (add-to-list 'ispell-dictionary-alist
                 '("hebrew8"
                   "[a-zA-Z\340-\372]"                 ;Latin and Hebrew
                   "[^a-zA-Z\340-\372]"
                   "['\"]" t ("-B") nil iso-8859-8))   ;Hebrew charset

    (setq ispell-dictionary "hebrew8")
    (ispell-change-dictionary "hebrew8")
    (set-default 'ispell-local-dictionary "hebrew8")

    ;; Adding the Hebrew dictionary to ispell menu
    (if (fboundp 'define-key-after)
        (define-key-after ispell-menu-map [ispell-select-hebrew8]
          '("Select Hebrew8 Dict" . (lambda()
                                      (interactive)
                                      (ispell-change-dictionary "hebrew8")))
          'american))

My .Xdefaults has:
emacs.pane.menubar.font:  -misc-fixed-medium-r-normal--13-120-75-75-c-80-iso8859-8
emacs.menu.popup.font:    -misc-fixed-medium-r-normal--13-120-75-75-c-80-iso8859-8


The Hebrew speller (hspell) is the the work of Dan Kenigsberg and Nadav
Har'El. The site URL: http://ivrix.org.il/projects/spell-checker/ (this
page is not accessible just now, but the hspell files are also here:
http://sf.net/project/showfiles.php?group_id=99645&package_id=107592 .

Ehud.


--
 Ehud Karni           Tel: +972-3-7966-561  /"\
 Mivtach - Simon      Fax: +972-3-7966-667  \ /  ASCII Ribbon Campaign
 Insurance agencies   (USA) voice mail and   X   Against   HTML   Mail
 http://www.mvs.co.il  FAX:  1-815-5509341  / \
 GnuPG: 98EA398D <http://www.keyserver.net/>    Better Safe Than Sorry

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: aspell and emacs
  2004-12-31 10:31 ` Ehud Karni
@ 2004-12-31 22:43   ` Neon Absentius
  2005-01-01 10:40     ` Eli Zaretskii
  2005-01-02 13:04     ` Ehud Karni
  0 siblings, 2 replies; 12+ messages in thread
From: Neon Absentius @ 2004-12-31 22:43 UTC (permalink / raw)


On Fri, Dec 31, 2004 at 12:31:27PM +0200, Ehud Karni wrote:
>-- 8< -- 
> An example for how to set the it to use the Hebrew dictionary is:
> 
>     (require 'ispell)
> 
>     ;; Tell emacs what constitutes a word.
>     (add-to-list 'ispell-dictionary-alist
>                  '("hebrew8"
>                    "[a-zA-Z\340-\372]"                 ;Latin and Hebrew
>                    "[^a-zA-Z\340-\372]"
>                    "['\"]" t ("-B") nil iso-8859-8))   ;Hebrew charset
> 
>     (setq ispell-dictionary "hebrew8")
>     (ispell-change-dictionary "hebrew8")
>     (set-default 'ispell-local-dictionary "hebrew8")
> 
>     ;; Adding the Hebrew dictionary to ispell menu
>     (if (fboundp 'define-key-after)
>         (define-key-after ispell-menu-map [ispell-select-hebrew8]
>           '("Select Hebrew8 Dict" . (lambda()
>                                       (interactive)
>                                       (ispell-change-dictionary "hebrew8")))
>           'american))

Thank you for your reply. Unfortunately it didn't help me as I was
looking specifically for help with aspell (and *not* ispell). The
greek dictionaries for ispell are outdated and I can't make them to
work with ispell anyway :(. There are greek dictionaries for aspell
and they work pretty good, so I wanted to use them in emacs.

I tried the solution you propose and it didn't work. The name of the
greek dictionary is "el" so when I tried your solution when I try to 
spell check a buffer I get 


  Starting new Ispell process... 
  ispell-init-process: Error: The file "/usr/lib/aspell/el" is not in
  the proper format.

Now the funny thing is that after that if I evaluate

     (setq ispell-dictionary "american")
     (ispell-change-dictionary "american")
     (set-default 'ispell-local-dictionary "american") 
 
and try to ispell a buffer I get a very similar message

  Starting new Ispell process...
  ispell-init-process: Error: The file
  "/usr/lib/aspell/english-med-only" is not in the proper format.

However if, instead, I use the menu and select the default dictionary
everything works just fine. When I do the same with the "el"
dictionary, ie if I set it to be the default and then select "default"
from the menu, I get an other error message

  ispell-process-line: Ispell misalignment: word `Faut' point 722;
  probably incompatible versions
 
Probably I am doing something stupid. 

Thanks anyway
N.A.
-- 
Charity in capitalism is like urinating to extinguish a forest fire.
    -- Neon Absentius
absent a.in.cirle sdf period lonestar period org
SDF Public Access UNIX System - http://sdf.lonestar.org

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: aspell and emacs
  2004-12-31 22:43   ` Neon Absentius
@ 2005-01-01 10:40     ` Eli Zaretskii
  2005-01-02 13:04     ` Ehud Karni
  1 sibling, 0 replies; 12+ messages in thread
From: Eli Zaretskii @ 2005-01-01 10:40 UTC (permalink / raw)


> Date: Fri, 31 Dec 2004 22:43:23 +0000
> From: Neon Absentius <absent@sdf.lonestar.org>
> 
> Thank you for your reply. Unfortunately it didn't help me as I was
> looking specifically for help with aspell (and *not* ispell). The
> greek dictionaries for ispell are outdated and I can't make them to
> work with ispell anyway :(. There are greek dictionaries for aspell
> and they work pretty good, so I wanted to use them in emacs.
> 
> I tried the solution you propose and it didn't work. The name of the
> greek dictionary is "el" so when I tried your solution when I try to 
> spell check a buffer I get 
> 
> 
>   Starting new Ispell process... 
>   ispell-init-process: Error: The file "/usr/lib/aspell/el" is not in
>   the proper format.

Please provide a more complete description of your ispell.el setup, in
particular how did you tell ispell.el to invoke aspell instead of the
default ispell.  (IIRC, aspell comes with a shell script called
"ispell" that makes aspell more compatible with ispell; did you try
using that script?)

Btw, it's possible that I missed something, but I cannot find the
error message like the above anywhere in ispell.el.  Can you trace
where it is coming from?

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: aspell and emacs
  2004-12-31 22:43   ` Neon Absentius
  2005-01-01 10:40     ` Eli Zaretskii
@ 2005-01-02 13:04     ` Ehud Karni
  1 sibling, 0 replies; 12+ messages in thread
From: Ehud Karni @ 2005-01-02 13:04 UTC (permalink / raw)
  Cc: help-gnu-emacs

On Fri, 31 Dec 2004 22:43:23 +0000, Neon Absentius <absent@sdf.lonestar.org> wrote:
>
> Thank you for your reply. Unfortunately it didn't help me as I was
> looking specifically for help with aspell (and *not* ispell). The
> greek dictionaries for ispell are outdated and I can't make them to
> work with ispell anyway :(. There are greek dictionaries for aspell
> and they work pretty good, so I wanted to use them in emacs.

I work with aspell too (it is called from hspell). The `ispell' is
the emacs package, not the external program.

You have to add:
    (setq ispell-program-name "aspell")
and everything will be OK (I hope).

> I tried the solution you propose and it didn't work. The name of the
> greek dictionary is "el" so when I tried your solution when I try to
> spell check a buffer I get
>
>
>   Starting new Ispell process...
>   ispell-init-process: Error: The file "/usr/lib/aspell/el" is not in
>   the proper format.
>
> Now the funny thing is that after that if I evaluate
>
>      (setq ispell-dictionary "american")
>      (ispell-change-dictionary "american")
>      (set-default 'ispell-local-dictionary "american")
>
> and try to ispell a buffer I get a very similar message
>
>   Starting new Ispell process...
>   ispell-init-process: Error: The file
>   "/usr/lib/aspell/english-med-only" is not in the proper format.
>
> However if, instead, I use the menu and select the default dictionary
> everything works just fine. When I do the same with the "el"
> dictionary, ie if I set it to be the default and then select "default"
> from the menu, I get an other error message
>
>   ispell-process-line: Ispell misalignment: word `Faut' point 722;
>   probably incompatible versions
>
> Probably I am doing something stupid.

It seems to me you work with the `ispell' program with the `aspell'
dictionaries.

ehud.


--
 Ehud Karni           Tel: +972-3-7966-561  /"\
 Mivtach - Simon      Fax: +972-3-7966-667  \ /  ASCII Ribbon Campaign
 Insurance agencies   (USA) voice mail and   X   Against   HTML   Mail
 http://www.mvs.co.il  FAX:  1-815-5509341  / \
 GnuPG: 98EA398D <http://www.keyserver.net/>    Better Safe Than Sorry

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2005-01-02 13:04 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-01-28  3:06 Aspell and Emacs Chris Swoyer
2004-01-28 21:50 ` Martin Stemplinger
2004-01-28 22:46   ` Chris Swoyer
2004-01-29  1:35     ` Tim McNamara
2004-01-28 23:18 ` Bruce Ingalls
2004-01-29  0:30   ` Chris Swoyer
2004-01-29 20:17   ` Kevin Rodgers
  -- strict thread matches above, loose matches on Subject: below --
2004-12-31  9:28 aspell and emacs Neon Absentius
2004-12-31 10:31 ` Ehud Karni
2004-12-31 22:43   ` Neon Absentius
2005-01-01 10:40     ` Eli Zaretskii
2005-01-02 13:04     ` Ehud Karni

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).