From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Nikolai Weibull Newsgroups: gmane.emacs.help Subject: Re: Getting Emacs to play nice with Hunspell and apostrophes Date: Sat, 7 Jun 2014 21:59:47 +0200 Message-ID: References: <83oay436nb.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1402171212 16729 80.91.229.3 (7 Jun 2014 20:00:12 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 7 Jun 2014 20:00:12 +0000 (UTC) Cc: Emacs Users To: Eli Zaretskii Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Jun 07 22:00:05 2014 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1WtMmb-0000GU-8V for geh-help-gnu-emacs@m.gmane.org; Sat, 07 Jun 2014 22:00:05 +0200 Original-Received: from localhost ([::1]:53013 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WtMma-0005Nq-Vx for geh-help-gnu-emacs@m.gmane.org; Sat, 07 Jun 2014 16:00:04 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:37498) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WtMmM-0005NX-MV for help-gnu-emacs@gnu.org; Sat, 07 Jun 2014 15:59:51 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WtMmL-0005C2-Nt for help-gnu-emacs@gnu.org; Sat, 07 Jun 2014 15:59:50 -0400 Original-Received: from mail-qg0-x235.google.com ([2607:f8b0:400d:c04::235]:33495) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WtMmK-0005Bm-Ab; Sat, 07 Jun 2014 15:59:48 -0400 Original-Received: by mail-qg0-f53.google.com with SMTP id f51so7152679qge.12 for ; Sat, 07 Jun 2014 12:59:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type:content-transfer-encoding; bh=Ts1bwYBHg++iFjpXCtWRHMtw8t6U2P8fzf1H1KF3JVc=; b=I78eRtmUXaPphNoTEPKBcU2Iw0BFGMqCJeM3f66FEZ2Gzx1gCkHA+DdP0qyPllc4OB qNbK34jdKhCNNnwm736m0v1MRulWqNh/Bh7r56qioOO+lAOAjcZSkiA2GLJyN7+MPJbe KhGOI4vJWSqtW8OTgc+zs425uENXg+irX8Tfes2bkFvGA2AKmuiblNHE2QI+PNhKsgvd kIxZ8HkNv70uluTeNQSn2EF0xKlaPmzVaH8NJtqZ5bqpN3ajiOQFDT7gVX0//ZCeU/gt yrhsAHqFbSl8tfK+Xk11mUq/BdmmOpeyN2iYnC+b4N6VuqQRe1zU3DdPijU87Hr83EMz U7kg== X-Received: by 10.140.38.18 with SMTP id s18mr19708967qgs.88.1402171187537; Sat, 07 Jun 2014 12:59:47 -0700 (PDT) Original-Received: by 10.140.95.114 with HTTP; Sat, 7 Jun 2014 12:59:47 -0700 (PDT) In-Reply-To: <83oay436nb.fsf@gnu.org> X-Google-Sender-Auth: ix2pmy2FUZO1GMn2JF0LqrHMxeQ X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2607:f8b0:400d:c04::235 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 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.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:98078 Archived-At: On Sat, Jun 7, 2014 at 8:40 PM, Eli Zaretskii wrote: >> Date: Sat, 7 Jun 2014 20:28:08 +0200 >> From: Nikolai Weibull >> >> On Sat, Jun 7, 2014 at 5:39 PM, Nikolai Weibull wrote: >> >> > It=E2=80=99s beyond me how this isn=E2=80=99t working, but I=E2=80=99m= sure I=E2=80=99m doing something wrong. >> >> I should perhaps also note that the only word in the sentence above >> that is seen as an error is =E2=80=9Cisn=E2=80=99t=E2=80=9D, as =E2=80= =9Cisn=E2=80=9D isn=E2=80=99t a word. I guess >> either Emacs or hunspell is ignoring single-character words =E2=80=9Cs= =E2=80=9D and >> =E2=80=9Cm=E2=80=9D after each of the other instances of =E2=80=98=E2=80= =99=E2=80=99 and =E2=80=9CIt=E2=80=9D and =E2=80=9CI=E2=80=9D are of >> course seen as correctly spelled words=E2=80=A6 > Emacs just goes with whatever the .aff file of the dictionary you use > says. And it cannot do anything else, because the speller uses that > dictionary, and decides by its rules what can and what cannot be in a > word. Yes, I realize that, but that raises the question of how =E2=80=98isn=E2=80= =99t=E2=80=99 will be parsed if I straight up add =E2=80=99 to WORDCHARS, but I guess that onl= y matters for the curses interface that I don=E2=80=99t use. > Look in the .aff file you use, and you will see that it knows about ' > and about n't and about 's, that's why these work. There's no magic > here. OK, so having read hunspell(5), it seems that my .aff that comes from OpenOffice doesn=E2=80=99t include =E2=80=9Cn't=E2=80=9D as a possible SFX. The .dic does list the word =E2=80=9Cisn't=E2=80=9D, however, so I=E2=80=99= m not sure what to make of this. The one from SCOWL, version 7.1.0, looks about the same as the OpenOffice o= ne. The one from Mozilla is also about the same. > So I think you must get a hold of a Hunspell-compliant dictionary that > knows about the =E2=80=99 apostrophe. Yes, I suppose so. One solution that seems to work is to add =E2=80=98=E2=80=99=E2=80=99 (or = =E2=80=98'=E2=80=99 to WORDCHARS and then change ispell-dictionary-alist to include =E2=80=98=E2=80=99=E2=80=99 = in the OTHERCHARS element. This works with hunspell 1.3.3 (which was released a couple of days ago and still doesn=E2=80=99t include the patch for handling offset= s correctly). Perhaps this should be handled automatically for OTHERCHARS in ispell.el?