From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Reuben Thomas Newsgroups: gmane.emacs.bugs Subject: bug#17742: Acknowledgement (Support for enchant?) Date: Sun, 18 Dec 2016 23:39:54 +0000 Message-ID: References: <834m2hjbmr.fsf@gnu.org> <83bmwfbxaf.fsf@gnu.org> <837f73bqwv.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=94eb2c05a18af598410543f75193 X-Trace: blaine.gmane.org 1482104489 26255 195.159.176.226 (18 Dec 2016 23:41:29 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 18 Dec 2016 23:41:29 +0000 (UTC) Cc: 17742@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Dec 19 00:41:24 2016 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cIl52-00062s-D5 for geb-bug-gnu-emacs@m.gmane.org; Mon, 19 Dec 2016 00:41:24 +0100 Original-Received: from localhost ([::1]:42556 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cIl56-0004eu-J0 for geb-bug-gnu-emacs@m.gmane.org; Sun, 18 Dec 2016 18:41:28 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:56432) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cIl4l-0004UE-0N for bug-gnu-emacs@gnu.org; Sun, 18 Dec 2016 18:41:08 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cIl4g-00026f-Mj for bug-gnu-emacs@gnu.org; Sun, 18 Dec 2016 18:41:07 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:59398) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cIl4g-00026V-Jm for bug-gnu-emacs@gnu.org; Sun, 18 Dec 2016 18:41:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1cIl4g-00058N-7n for bug-gnu-emacs@gnu.org; Sun, 18 Dec 2016 18:41:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Reuben Thomas Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 18 Dec 2016 23:41:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 17742 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 17742-submit@debbugs.gnu.org id=B17742.148210440319654 (code B ref 17742); Sun, 18 Dec 2016 23:41:02 +0000 Original-Received: (at 17742) by debbugs.gnu.org; 18 Dec 2016 23:40:03 +0000 Original-Received: from localhost ([127.0.0.1]:46564 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cIl3i-00056r-Hf for submit@debbugs.gnu.org; Sun, 18 Dec 2016 18:40:03 -0500 Original-Received: from mail-qk0-f169.google.com ([209.85.220.169]:35836) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cIl3g-00056K-3E for 17742@debbugs.gnu.org; Sun, 18 Dec 2016 18:40:01 -0500 Original-Received: by mail-qk0-f169.google.com with SMTP id n204so143647623qke.2 for <17742@debbugs.gnu.org>; Sun, 18 Dec 2016 15:40:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sc3d.org; s=google; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=b3FbgNtYavObIZkHHCo19Eyjq3AjGAfAiir0qUPMXsc=; b=xX08oqPAxVwmgLl28Z2vem9qTdCp/fDdxe3K42eV0nV/KbQNKCg5Mt2r+uxkHKpTvF G2+IlR1dVvBNszBef56U4NDiKijMXNj3SOp/GHb4KuM9zfM0mj1LQqrGMsFuWiURdU3X CGTOkQwNUCXKVsvapk4VUEgCyAKPsWNNkkqFE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=b3FbgNtYavObIZkHHCo19Eyjq3AjGAfAiir0qUPMXsc=; b=DlrXwEwLQlaPa+y0ZTs67CR3080tDhYmizk+pZmDg289drr1K61ClaMpaA015TD17W HrGNn28SxSp1i6RoUHVAJFFcH9Bij4LpPo7HLjGYdcc1GMpPeDxzBEuU1IqoTk33RxiH g1P3f+q2AHhaN9Nc0JqYuemdlo3yeLCfJjOZnMU/61+V376Irt1bG/PGeykE8iXrvg0q h077bbvegRpP3x+CRra2zOTGSkrbdjPiE5S7p+sEoTZ9ER8C072ZofZELT+wKA2FRTcz YVvN58792qBfYYdsj2c55RAkGLAweCsaaWooY/e6cxfdBGB1Lo158qoBzFcRQzLQiH8C pZkw== X-Gm-Message-State: AIkVDXLSXElFfvyVKqZdiIqxh/eVtITUdZR3jQtff+gNqAO2vvpKL3Uxc2UbvfOMhiCMJQEMTfZUSlPjqeAHnqmZ X-Received: by 10.55.124.5 with SMTP id x5mr319478qkc.9.1482104394579; Sun, 18 Dec 2016 15:39:54 -0800 (PST) Original-Received: by 10.140.88.51 with HTTP; Sun, 18 Dec 2016 15:39:54 -0800 (PST) In-Reply-To: <837f73bqwv.fsf@gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:127149 Archived-At: --94eb2c05a18af598410543f75193 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 13 December 2016 at 18:54, Eli Zaretskii wrote: > > From: Reuben Thomas > > Date: Tue, 13 Dec 2016 18:26:43 +0000 > > Cc: 17742@debbugs.gnu.org > > > > I understand that Enchant doesn't yet support these features, but in > > that case we must provide our users with some way of customizing these > > settings, we cannot silently use defaults that are most probably > > inappropriate, even if they are 90% correct. > > > > =E2=80=8BThe way to customize it is surely the same as currently, namel= y=E2=80=8B to > customize ispell-dictionary-alist?=E2=80=8B > > That's okay, but then ispell.el shouldn't be generating dictionary > entries, but instead should leave that to the user, as we do with > Ispell. > > > Given that even management of personal word lists needs a patch to > Enchant, it seems to me better to first > > try to engage with the Enchant maintainers on this. There's also one > obvious question, namely, what do other > > Enchant users do? Enchant is used in Abiword (free word processor), > Pidgin (free IM client) etc. So, I shall > > look into this. > > Thanks. > =E2=80=8BI have not had any response to my enquiries yet, but I did some re= search, and neither GNU Aspell nor hunspell offer any way to get this information (about character classes of dictionaries) via their APIs. This suggests that they do not see a need for it. Perhaps it is worth confirming whether Emacs really needs this information? As far as I can see, it is used only in flyspell-word, for per-word spell-checking. (The only caller outside flyspell.el is erc, which has a FIXME saying not to call flyspell-word.) As far as I can see, the code assumes that words are a convenient unit to check and cache, though there's no definite requirement for that: in particular, the spelling checkers will say what words are incorrectly spelled and where they are without having to be given precisely the word. I guess that other editors and word processors work this way. For example, aspell.h contains the following notice about aspell_document_checker_process: * The string passed in should only be split on * white space characters. So a reasonable definition of cache units (I will not say "words" any more) might be whitespace-delimited strings. This would not need casechars, not-casechars, otherchars and many-otherchars-p. I've put this on my to-investigate list for the future; of course, if there's an obvious reason it wouldn't work, do let me know! --=20 http://rrt.sc3d.org --94eb2c05a18af598410543f75193 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
On = 13 December 2016 at 18:54, Eli Zaretskii <eliz@gnu.org> wrote:
> From: Reuben Thomas <rrt@sc3d.org>
> Date: Tue, 13 Dec 2016 18:26:43 +0000
> Cc: 17742@d= ebbugs.gnu.org
>
>=C2=A0 I understand that Enchant doesn't yet support these features= , but in
>=C2=A0 that case we must provide our users with some way of customizing= these
>=C2=A0 settings, we cannot silently use defaults that are most probably=
>=C2=A0 inappropriate, even if they are 90% correct.
>
> =E2=80=8BThe way to customize it is surely the same as currently, name= ly=E2=80=8B to customize ispell-dictionary-alist?=E2=80=8B

That's okay, but then ispell.el shouldn't be generating dict= ionary
entries, but instead should leave that to the user, as we do with
Ispell.

> Given that even management of personal word lists needs a patch to Enc= hant, it seems to me better to first
> try to engage with the Enchant maintainers on this. There's also o= ne obvious question, namely, what do other
> Enchant users do? Enchant is used in Abiword (free word processor), Pi= dgin (free IM client) etc. So, I shall
> look into this.

Thanks.

=E2=80=8BI have not had any response to my e= nquiries yet, but I did some research, and neither GNU Aspell nor hunspell = offer any way to get this information (about character classes of dictionar= ies) via their APIs.

This suggests that they do not see a need for it. Perhaps it is worth con= firming whether Emacs really needs this information?

As far as I can see, it is used only in flyspel= l-word, for per-word spell-checking. (The only caller outside flyspell.el i= s erc, which has a FIXME saying not to call flyspell-word.) As far as I can= see, the code assumes that words are a convenient unit to check and cache,= though there's no definite requirement for that: in particular, the sp= elling checkers will say what words are incorrectly spelled and where they = are without having to be given precisely the word. I guess that other edito= rs and word processors work this way.

For example, aspell.h contains the following notice about aspe= ll_document_checker_process:

=C2=A0* The string passed in should= only be split on
=C2=A0* white space cha= racters.

So a reasonable definition of cache units (I will not say "word= s" any more) might be whitespace-delimited strings. This would not nee= d casechars, not-casechars, otherchars and many-otherchars-p.

I've put th= is on my to-investigate list for the future; of course, if there's an o= bvious reason it wouldn't work, do let me know!
<= br>
--
--94eb2c05a18af598410543f75193--