From 92c7826aa19c6988a969c32c35b3d41867469d00 Mon Sep 17 00:00:00 2001 From: Thomas Jost Date: Thu, 16 Feb 2012 18:47:42 +0100 Subject: [PATCH] Re: Spellcheck second language --- f2/557eef6484ca33721fb6407311edabf609872a | 138 ++++++++++++++++++++++ 1 file changed, 138 insertions(+) create mode 100644 f2/557eef6484ca33721fb6407311edabf609872a diff --git a/f2/557eef6484ca33721fb6407311edabf609872a b/f2/557eef6484ca33721fb6407311edabf609872a new file mode 100644 index 000000000..2e279650b --- /dev/null +++ b/f2/557eef6484ca33721fb6407311edabf609872a @@ -0,0 +1,138 @@ +Return-Path: +X-Original-To: notmuch@notmuchmail.org +Delivered-To: notmuch@notmuchmail.org +Received: from localhost (localhost [127.0.0.1]) + by olra.theworths.org (Postfix) with ESMTP id E91E7429E48 + for ; Thu, 16 Feb 2012 09:47:51 -0800 (PST) +X-Virus-Scanned: Debian amavisd-new at olra.theworths.org +X-Spam-Flag: NO +X-Spam-Score: -0.1 +X-Spam-Level: +X-Spam-Status: No, score=-0.1 tagged_above=-999 required=5 + tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1] + autolearn=disabled +Received: from olra.theworths.org ([127.0.0.1]) + by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) + with ESMTP id I90rlXep7kpP for ; + Thu, 16 Feb 2012 09:47:47 -0800 (PST) +Received: from ks3536.kimsufi.com (schnouki.net [87.98.217.222]) + by olra.theworths.org (Postfix) with ESMTP id A019B429E42 + for ; Thu, 16 Feb 2012 09:47:47 -0800 (PST) +Received: from thor.loria.fr (thor.loria.fr [152.81.12.250]) + by ks3536.kimsufi.com (Postfix) with ESMTPSA id 3D0076C000B; + Thu, 16 Feb 2012 18:47:46 +0100 (CET) +DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=schnouki.net; + s=key-schnouki; t=1329414466; + bh=PYiM5D3bA5cBMl0/b92QbcgfH0w58odtOb+7Ljhp1jg=; + h=From:To:Subject:In-Reply-To:References:Date:Message-ID: + MIME-Version:Content-Type; + b=gmgcTJSc+4VGhTbws7002Z74cUZnZoyaqE2YJMoiv+OgOeOUOMJqWJL40g88yyngm + j8cweAFzouSotyj3Lm4m38oUHhKgyuSPQmVbYpXyfC7H0duckys0aI7wCiGFSNVBOr + dG//aLHWY3EV2U5WOAjsF88eaqLaBQrlsy1LghaQ= +From: Thomas Jost +To: Philippe LeCavalier , notmuch@notmuchmail.org +Subject: Re: Spellcheck second language +In-Reply-To: <878vk2ohgp.fsf@plc.plecavalier.com> +References: <878vk2ohgp.fsf@plc.plecavalier.com> +User-Agent: Notmuch/0.11.1+214~g9a53dc2 (http://notmuchmail.org) + Emacs/24.0.93.1 (x86_64-unknown-linux-gnu) +Date: Thu, 16 Feb 2012 18:47:42 +0100 +Message-ID: <87obsyd60x.fsf@thor.loria.fr> +MIME-Version: 1.0 +Content-Type: multipart/signed; boundary="=-=-="; + micalg=pgp-sha1; protocol="application/pgp-signature" +X-BeenThere: notmuch@notmuchmail.org +X-Mailman-Version: 2.1.13 +Precedence: list +List-Id: "Use and development of the notmuch mail system." + +List-Unsubscribe: , + +List-Archive: +List-Post: +List-Help: +List-Subscribe: , + +X-List-Received-Date: Thu, 16 Feb 2012 17:47:52 -0000 + +--=-=-= +Content-Type: text/plain; charset=utf-8 +Content-Transfer-Encoding: quoted-printable + +On Thu, 16 Feb 2012 11:45:10 -0500, Philippe LeCavalier wrote: +> Hi. +>=20 +> I get this[1] when envoking keybindings to a second language +> flyspell. Any ideas? I've already tried alternate titles to reference +> the dictionary in question ie french, francais and fran=C3=A7ais to no av= +ail. +>=20 +> Also, how would I apply a variation to the dictionary ie. fr_ca? +>=20 +> ref. +> [1] ispell-change-dictionary: Undefined dictionary: fran=C3=A7ais +>=20 +> rel sys details: +> emacs 23.3-9.fc16 +> hunspell 1.3.2-1.fc16 +> hunspell-en 0.20110318-1.fc16 +> hunspell-fr 4.1-1.fc16 +>=20 +> Please ask if you need more info. + +Hi Philippe, + +Do you have aspell? If you do, do you also have aspell-fr? I don't know +ispell.el very well, but apparently it will try to use aspell, then +ispell, then hunspell in that order. So if you have /usr/bin/aspell but +not the French aspell dictionary, that may explain your problem. + +Now for fr_CA... I don't use it myself (only fr_FR) and apparently +there's no specific file for fr_CA (nor fr_BE btw) in aspell-fr. So I +guess you should try to stick with "francais". + +If you *really* want to use fr_CA, you may have to switch to hunspell, +since hunspell-fr *has* a dictionary for fr_CA. The problem is then to +tell emacs about this dictionary. Here's something that almost works: + + (setq ispell-program-name "/usr/bin/hunspell" + ispell-extra-args '("-i" "latin1")) + (add-to-list 'ispell-local-dictionary-alist + (cons "fr_CA" (cdr (assoc "francais" ispell-dictionary-ba= +se-alist)))) + +(it copies settings from the fr_FR dictionary but names it fr_CA). +Problems: +=2D you need to enter the encoding manually to avoid getting such errors: + UTF-8 encoding error. Missing continuation byte in 0. [...] + but of course this means that this won't work in UTF-8 buffers... +=2D using these settings, I get another error when changing the dictionary + to american and running flyspell-buffer ("Can't check region"). I have + to revert to aspell for it to work again. + +So even if it's not a perfect solution, you should probably keep on +using "francais" with aspell. + +Hope this helps. + +Best regards + +=2D-=20 +Thomas/Schnouki + +--=-=-= +Content-Type: application/pgp-signature + +-----BEGIN PGP SIGNATURE----- +Version: GnuPG v1.4.12 (GNU/Linux) + +iQEcBAEBAgAGBQJPPUE/AAoJEOQWxbmv9eBxkL8H/1RdEdHff4L0PYJFEzRIe+zJ +JhM+IJ40bVNxHuhNHwhnkNBB5+ZxfyEPyQxunjCOPC+eOloNIyzGU7WK8g5p1UuY +FzDxYUYlYVEWUX7I0l1nBtJMQgBDX1gZVPcXJ4zuYMXL4Mw5rg8uy40H9yg/OBy4 +vTq3lhq5XWc4is0geyBD8VqUCd0FKs9mK5w2ik06is+jl3sbBsjhp9yTxN8RH8ha +5AZvgIrbYtbbC/himD1BPUN5yBGFkaV5LSnxPMJHKfEyyiZGPhbV7jKnATLxlu16 +PUjQtWV8zALScbiYUal7pq3LwnfSJjJWIufpWgZT0nrnq6MGqWcmfuKXP0pZVkg= +=Y7eo +-----END PGP SIGNATURE----- +--=-=-=-- -- 2.26.2