[an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] (none) [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] (none) [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive]
 
[an error occurred while processing this directive] [an error occurred while processing this directive]
Skåne Sjælland Linux User Group - http://www.sslug.dk Home   Subscribe   Mail Archive   Forum   Calendar   Search
MhonArc Date: [Date Prev] [Date Index] [Date Next]   Thread: [Date Prev] [Thread Index] [Date Next]   MhonArc
 

Re: [EMACS] Flere stavekontrolknapper i Gnus?



Vivi Petersen skrev:

> Det ved jeg ikke, men kan du nøjes med en enkelt knap, som skifter
> sprog afhængig af hvilken gruppe du er i?

Det går nok.

> For det kan vist gøres ved hjælp af følgende (fra afsnittet "Mail
> and Post" i Gnus-manualen):

>    If you want to change the `ispell' dictionary based on what group
> you're in, you could say something like the following:
> 
>      (add-hook 'gnus-select-group-hook
>                (lambda ()
>                  (cond
>                   ((string-match
>                     "^de\\." (gnus-group-real-name gnus-newsgroup-name))
>                    (ispell-change-dictionary "deutsch"))
>                   (t
>                    (ispell-change-dictionary "english")))))
> 
>    Modify to suit your needs.

Det ser desværre ikke ud til at have den ønskede effekt.  Jeg puttede
en variant af det ovenstående i "~/.gnus" og genstartede Gnus.  Men
selvom jeg er inde i en "sslug."-gruppe lige nu, så vil Gnus gerne
køre stavekontrol på færøsk og ikke på dansk.  Her er min variant af
opsætningen ovenfor:

----------------------------------------------------------------------
;; Skift sprog i stavekontrollen, når der skiftes nyhedsgruppe:
(add-hook 'gnus-select-group-hook
	  (lambda ()
	    (cond
	     ((string-match
	       "^de\\." (gnus-group-real-name gnus-newsgroup-name))
	      (ispell-change-dictionary "deutsch"))
	     ((string-match
	       "^comp\\." (gnus-group-real-name gnus-newsgroup-name))
	      (ispell-change-dictionary "english"))
	     ((string-match
	       "^fo\\." (gnus-group-real-name gnus-newsgroup-name))
	      (ispell-change-dictionary "føroyskt"))
	     ((string-match
	       "^flug\\." (gnus-group-real-name gnus-newsgroup-name))
	      (ispell-change-dictionary "føroyskt"))
	     (t
	      (ispell-change-dictionary "dansk")))))
----------------------------------------------------------------------

I »Messages«-bufferen står der (blandt andet):

----------------------------------------------------------------------
Fetching headers for sslug.emacs...done
Ispell process killed
(Next local Ispell command will use dansk dictionary)
Scoring...
Scoring article 116 of 116...
Scoring...done
Generating summary...done
Auto-saving...
Mark set [3 times]
Starting new Ispell process...
Spell checking region using default dictionary...
Exited spell-checking
Mark set [2 times]
Auto-saving...done
Mark set [7 times]
Auto-saving...done
Mark set [2 times]
----------------------------------------------------------------------

Så det ser ud til at der bliver skiftet til dansk og så tilbage til
standardindstillingen (færøsk).  Hvorfor mon det?

Hvis jeg i stedet skifter til dansk via menuerne virker det.

Jacob
-- 
"Nobody writes jokes in base 13."
 Douglas Adams



 
Home   Subscribe   Mail Archive   Index   Calendar   Search

 
 
Questions about the web-pages to <www_admin>. Last modified 2005-08-10, 20:10 CEST [an error occurred while processing this directive]
This page is maintained by [an error occurred while processing this directive]MHonArc [an error occurred while processing this directive] # [an error occurred while processing this directive] *