From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Felix Dietrich Newsgroups: gmane.emacs.help Subject: Re: ispell select Emacs dictionary on Debian Date: Tue, 27 Jul 2021 07:17:06 +0200 Message-ID: <87r1fkgwtp.fsf@sperrhaken.name> References: <8735s63leh.fsf@zoho.eu> <874kcli3uk.fsf@sperrhaken.name> <87pmv725un.fsf@zoho.eu> <87lf5v24xb.fsf_-_@zoho.eu> <87y29uggv0.fsf@sperrhaken.name> <87k0ldylab.fsf@zoho.eu> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="18743"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Tue Jul 27 07:17:49 2021 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1m8FTR-0004iQ-St for geh-help-gnu-emacs@m.gmane-mx.org; Tue, 27 Jul 2021 07:17:49 +0200 Original-Received: from localhost ([::1]:54038 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m8FTP-0000HS-Vh for geh-help-gnu-emacs@m.gmane-mx.org; Tue, 27 Jul 2021 01:17:48 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:39302) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m8FT1-0000HA-1P for help-gnu-emacs@gnu.org; Tue, 27 Jul 2021 01:17:23 -0400 Original-Received: from mout.kundenserver.de ([212.227.126.135]:43991) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m8FSu-0006Mn-4A for help-gnu-emacs@gnu.org; Tue, 27 Jul 2021 01:17:22 -0400 Original-Received: from localhost ([78.54.156.158]) by mrelayeu.kundenserver.de (mreue012 [212.227.15.167]) with ESMTPSA (Nemesis) id 1MOV26-1liSAw2BcE-00PuXX for ; Tue, 27 Jul 2021 07:17:12 +0200 In-Reply-To: <87k0ldylab.fsf@zoho.eu> (Emanuel Berg via Users list for the's message of "Mon, 26 Jul 2021 02:24:28 +0200") X-Provags-ID: V03:K1:5pTWfDLTfQsQvh9WGxXHhTLWMLtixrnA8+0NwwNJElniUO8h66X yUcFE52HcpwaBhystLqJ8dHHIyltiubkKYhrUQKmG9uIGB7rdnDXwDE0uO/lVSR5UXoYqPm ZMSNjTrFmNVXe6lV5HRJXsyFPDiaS8JBM1dHGJLolskcZDnrUDRjlMePcTfAd8/cCtm1w3F GWDyitQQxkh/Jlh4oTa2g== X-UI-Out-Filterresults: notjunk:1;V03:K0:G4nNYtPyMTw=:ibXDHvkhDXdBciHnhsJYGy qFrLEklj2iUTneSIQZEp9DM2bHah1ALF6sZxRL0j6XJV5dqJyXL3dcHWzaqSQ+uKnX1MQ1w0R pgk0O0YcYo2GwL2ZXZ/CToZ6Sgu4gD3qzpiXV9F2+pNaRX5yu5uV5XjgO8XPPiuLxpxUJQU6+ DNLcm3ccBb8jwNLJVz47Mixhwr4OkfxoSJYkVVx6r3SRjnIIsmV8QsotqGEezzIAQ5JFXGarP 7ufUXU6mO7q9nm5fWmy6pI+i/2Af1ud31w7klooRwlzpzvq6i4+hz6fEe2Xd89X7NSbeF2Ua0 qkgcMd4NSu5uZejI39plOBeGBCQ2p8XCF5fi/PaUnGd2b+6HZZE+/TqY5Nfnmu51YR2Wfeaqh b1yZ6VEQnVpxrbjMCbc94ft+sV+XsLJ66to0iOS2wktbZp3Yb/35LfQvNZDGjQFcLBzIa+Dwa ZzrAvkb33EunNSUXVXfSv9EnVcU5SxMLBtysGo7mUV0SDBPpIWldEh5cYNp41wG2p5ncdQ6yS YKAv1fWxOMZhMcylu+E4cqM4TFZAkXk8P8DZbyL9UJbusqj8txnQNXCVOVA472wO5GseCR+7T Vp3t35G7kgEd3E0OpCa5QRUrQ0vE9Zn5nwYK+Zq/7atlfnV5/dru8wslLfmBabhR2mwNz5OZr pp+HCfZMUNlQQhU5JSUbnqi3jnYkhIAgGj4LDxoNScOiG2FmwpTsITkwNNRDaG1sccOPnxMnP fXj1rXdOXBPr6Q9Owc1Q6W7giIjPR+GT9mhU+mGyUVrjofXLuCRn4eq0KOz2f4sNEfpF1K7V Received-SPF: none client-ip=212.227.126.135; envelope-from=felix.dietrich@sperrhaken.name; helo=mout.kundenserver.de X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_NONE=0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.io gmane.emacs.help:132116 Archived-At: Emanuel Berg via Users list for the GNU Emacs text editor writes: > As described in the previous post, Debian seems to react upon the > installation of the iamerican-insane package as with the superuser > script [select-default-ispell] to set the dictionary that alternative > does show up. The iamerican packages call in their postinst script [1] =E2=80=9Cupdate-default-ispell=E2=80=9D which will call the function =E2=80=9Cbuild_emacsen_support=E2=80=9D; this function creates the file with entries for =E2=80=98ispell-dictionary-alist=E2=80=99 (indirectly, see the function =E2=80=98debian-ispell-initialize-dicts-alist=E2=80=99 and the hook =E2=80=98ispell-initialize-spellchecker-hook=E2=80=99). > However after that with `ispell-change-dictionary' the > alternatives are still only > > american > default > svenska =E2=80=9Cemacsen-ispell-dicts.el=E2=80=9D is only read at start-up [2]. If= you install a new dictionary, an already running Emacs will not know about it. You may try to reinitialise the dictionary with the following snippet: (progn (setq debian-ispell-only-dictionary-alist nil debian-aspell-only-dictionary-alist nil debian-hunspell-only-dictionary-alist nil ispell-dictionary-alist nil) (load-file "/var/cache/dictionaries-common/emacsen-ispell-dicts.el") ;; There is a setter associated with =E2=80=98ispell-program-name=E2= =80=99 which ;; calls =E2=80=98ispell-set-spellchecker-params=E2=80=99. Calling t= his function ;; directly does not work; I don=CA=BCt understand why. (setq ispell-program-name "ispell")) For testing purposes, start Emacs with the =E2=80=9C-q=E2=80=9D (=E2=80=9C-= -no-init-file=E2=80=9D) switch. Do the dictionaries show up then in the dialog of =E2=80=98ispell-change-dictionary=E2=80=99? Do you use a custom built Emac= s or the Debian package? > If I remove all iamerican-* packages the american alternative > go away. I don't know if this is related to the iamerican > package in particular but that seems reasonable. It is connected to the action of removing the dictionary: ispell filters the list of =E2=80=98ispell-dictionary-alist=E2=80=99 for the dialog: it wi= ll only display those entries whose dictionary files exist. > But then why aren't the iamerican-small, iamerican-large, > iamerican-huge, and iamerican-insane there whenever _they_ > are installed? To reiterate: their entries are added on installation of the respective package to the file emacsen-ispell-dicts.el; this file is only loaded at start-up. > PS. The Swedish dictionary doesn't work either. It saysff > "ispell-init-process: Illegal format hash table > /usr/lib/ispell/svenska.hash - expected magic2 0x9602, got > 0x414c" Does not work for me either. Seems like a bug. Please report it. Meanwhile, try recreating the .hash file manually (requires the wswedish package): buildhash /usr/share/dict/svenska /usr/lib/ispell/svenska.aff \ /usr/lib/ispell/svenska.hash Footnotes: [1] If you have the package installed you may read their content here: . Otherwise, download the package and open it: the file is in the subarchive =E2=80=9Ccontrol.tar.xz". [2] --=20 Felix Dietrich