Le Thu, 7 Dec 2006 21:26:27 +0100
Christophe Gaubert <[EMAIL PROTECTED]> a écrit :

> Je crois qu'il est possible de l'avoir avec emacs.... Il y a déjà
> l'appel à aspell/myspell qui est possible, mais je crois qu'un package
> existe pour la correction en temps réel.

Ajouter, dans son .emacs :

;; correction orthographique
;; control $      : vérifie la région ou le buffer
;; meta $         : vérifie une mot
;; control meta $ : change de dictionnaire
(defun ispell-check ()
  (interactive)
  (if mark-active
          (if (< (mark) (point))
                  (ispell-region (mark) (point))
                (ispell-region (point) (mark)))
        (ispell-buffer)))
(global-set-key [(control $)] `ispell-check)
(global-set-key [(meta $)] `ispell-word)
(global-set-key [(control meta $)] `ispell-change-dictionary)
(setq ispell-program-name "aspell")
(setq ispell-dictionary "francais")
(setq ispell-local-dictionary "francais")
;; Correction orthographique à la volée
(add-hook 'text-mode-hook
                  '(lambda ()
                         (flyspell-mode)
                         (turn-on-auto-fill)
                         ))


-- 
Denis

=========================================
Vous souhaitez acquerir votre pack ou des services Mandriva?
Rendez-vous sur "http://store.mandriva.com";.
Rejoignez le club Mandriva : http://club.mandriva.com
=========================================

Répondre à