From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#49982: 27.2; ispell.el fails to find a Hunspell dictionary to use as default despite ispell-dictionary being set Date: Tue, 10 Aug 2021 22:29:43 +0300 Message-ID: <834kbxf68o.fsf@gnu.org> References: <59517c95-6568-f646-7097-c601cc9657c9@kisaragi-hiu.com> <83h7fxfft0.fsf@gnu.org> <54d5e013-aeff-ef7b-ad9e-e4c8dfa72d37@kisaragi-hiu.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="18657"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 49982@debbugs.gnu.org To: Kisaragi Hiu Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Aug 10 21:30:12 2021 Return-path: Envelope-to: geb-bug-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 1mDXRz-0004dR-NX for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 10 Aug 2021 21:30:11 +0200 Original-Received: from localhost ([::1]:59592 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mDXRy-00017f-IP for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 10 Aug 2021 15:30:10 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:37516) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mDXRq-00017D-QS for bug-gnu-emacs@gnu.org; Tue, 10 Aug 2021 15:30:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:49300) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mDXRq-00054H-J7 for bug-gnu-emacs@gnu.org; Tue, 10 Aug 2021 15:30:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mDXRq-0006EX-9t for bug-gnu-emacs@gnu.org; Tue, 10 Aug 2021 15:30:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 10 Aug 2021 19:30:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 49982 X-GNU-PR-Package: emacs Original-Received: via spool by 49982-submit@debbugs.gnu.org id=B49982.162862378923917 (code B ref 49982); Tue, 10 Aug 2021 19:30:02 +0000 Original-Received: (at 49982) by debbugs.gnu.org; 10 Aug 2021 19:29:49 +0000 Original-Received: from localhost ([127.0.0.1]:60846 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mDXRY-0006Db-Us for submit@debbugs.gnu.org; Tue, 10 Aug 2021 15:29:49 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:56966) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mDXRT-0006DH-QS for 49982@debbugs.gnu.org; Tue, 10 Aug 2021 15:29:44 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:33674) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mDXRO-0004kd-7x; Tue, 10 Aug 2021 15:29:34 -0400 Original-Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:2958 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mDXRN-00015q-QV; Tue, 10 Aug 2021 15:29:34 -0400 In-Reply-To: <54d5e013-aeff-ef7b-ad9e-e4c8dfa72d37@kisaragi-hiu.com> (message from Kisaragi Hiu on Wed, 11 Aug 2021 03:51:22 +0900) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:211537 Archived-At: > From: Kisaragi Hiu > Cc: 49982@debbugs.gnu.org > Date: Wed, 11 Aug 2021 03:51:22 +0900 > > Thank you for the response! Let me try to add some clarifications (that > hopefully don't sound too harsh): > > > First, yours is an unusual use case, I think: when Hunspell is > > installed, the dictionary that corresponds to the locale is always > > installed, because otherwise Hunspell will not work reliably from the > > shell command line. > > I'm fairly certain my use case isn't unusual. > > There are no easily installable Hunspell dictionaries for, among other > languages: > > - Any variant of Chinese (Mandarin) > - Japanese > - Kazakh > - Khmer > - Malay > > Every user of any of these languages who tries to set up Hunspell > along with ispell.el and Flyspell has to find or invent a poorly > documented workaround. > > - [[https://texwiki.texjp.org/?Hunspell][TeXJP (Japanese) mentions]] > "add[ing] the DICTIONARY or WORDLIST environment variables if needed" > (「また、必要に応じて環境変数DICTIONARYやWORDLISTを指定しておきます。」) > - [[https://home.hirosaki-u.ac.jp/heroic-2020/1575/][Hirosaki University > Information Technology Center PC lab's tutorial to spellchecking in > Emacs]] sets DICTIONARY to en_US > - 200ok.ch (developer of Organice)'s > [[https://200ok.ch/posts/2020-08-22_setting_up_spell_checking_with_multiple_dictionaries.html][tutorial > for using multiple dictionaries for Hunspell + ispell.el]] mentions Indeed, defining DICTIONARY in the environment is the way to control the default dictionary. It is documented in the Hunspell's man page. Why cannot it be the solution for when no Hunspell dictionary could be found that matches the locale? Using $DICTIONARY should solve your problem both inside Emacs and outside it.