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#50241: flyspell doesn't work with multiple dictionaries Date: Sun, 29 Aug 2021 09:12:58 +0300 Message-ID: <83h7f8n5hx.fsf@gnu.org> References: <581ffd00b0c4a0762689a423aff0ee13b5c85e52.camel@yandex.ru> <83lf4lmm8k.fsf@gnu.org> <83k0k5mked.fsf@gnu.org> <8658b0b457b9fc41624b454a0534013173de37ce.camel@yandex.ru> <65a1ecacc7ae808fc6fbc204094375604352c4aa.camel@yandex.ru> <1b2e0b953b4036fe10d45451e6b1381fe8931eeb.camel@yandex.ru> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="37892"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 50241@debbugs.gnu.org To: Konstantin Kharlamov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Aug 29 08:14:09 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 1mKE53-0009gr-IM for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 29 Aug 2021 08:14:09 +0200 Original-Received: from localhost ([::1]:33478 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mKE51-0007E5-Nc for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 29 Aug 2021 02:14:07 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:43948) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mKE4w-0007Du-Km for bug-gnu-emacs@gnu.org; Sun, 29 Aug 2021 02:14:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:43835) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mKE4w-0002ea-BQ for bug-gnu-emacs@gnu.org; Sun, 29 Aug 2021 02:14:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mKE4w-00065G-2Y for bug-gnu-emacs@gnu.org; Sun, 29 Aug 2021 02:14: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: Sun, 29 Aug 2021 06:14:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 50241 X-GNU-PR-Package: emacs Original-Received: via spool by 50241-submit@debbugs.gnu.org id=B50241.163021760023324 (code B ref 50241); Sun, 29 Aug 2021 06:14:02 +0000 Original-Received: (at 50241) by debbugs.gnu.org; 29 Aug 2021 06:13:20 +0000 Original-Received: from localhost ([127.0.0.1]:55381 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mKE4F-000648-Mo for submit@debbugs.gnu.org; Sun, 29 Aug 2021 02:13:19 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:55994) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mKE4C-00063t-1u for 50241@debbugs.gnu.org; Sun, 29 Aug 2021 02:13:18 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:58678) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mKE46-0001yZ-KZ; Sun, 29 Aug 2021 02:13:10 -0400 Original-Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:1935 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 1mKE46-0007oe-7g; Sun, 29 Aug 2021 02:13:10 -0400 In-Reply-To: <1b2e0b953b4036fe10d45451e6b1381fe8931eeb.camel@yandex.ru> (message from Konstantin Kharlamov on Sat, 28 Aug 2021 23:42:08 +0300) 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:212915 Archived-At: > From: Konstantin Kharlamov > Cc: 50241@debbugs.gnu.org > Date: Sat, 28 Aug 2021 23:42:08 +0300 > > Okay, I finally found the working combination, it is: > > (progn > (require 'ispell) > (setq ispell-program-name "hunspell") > (ispell-set-spellchecker-params) > (ispell-hunspell-add-multi-dic "ru_RU,en_US") > (ispell-change-dictionary "ru_RU,en_US") > (flyspell-mode 1) > ) > > So, the magical function is `(ispell-set-spellchecker-params)`. Judging by its description, it has to be called before any ispell usage. > > I can probably call it manually, but I presume the behaviour needs fixing. I'm not sure I agree. These are commands that are supposed to be invoked interactively, in the order I've shown, which works. If you want to make this part of your initialization, you need to figure out the required sequence of calls, which you did.