From: Eli Zaretskii <eliz@gnu.org>
To: Ian Dunn <dunni@gnu.org>
Cc: emacs-devel@gnu.org
Subject: Re: [ELPA] New package: Auto Correct Mode
Date: Sun, 27 Aug 2017 19:34:26 +0300 [thread overview]
Message-ID: <83shgd3r71.fsf@gnu.org> (raw)
In-Reply-To: <87zialc7wx.fsf@escafil> (message from Ian Dunn on Sun, 27 Aug 2017 12:06:06 -0400)
> From: Ian Dunn <dunni@gnu.org>
> Date: Sun, 27 Aug 2017 12:06:06 -0400
>
> I'd like to submit auto-correct.el as a single-file package to ELPA. It's a small package that integrates with ispell and abbrev to provide auto-correct functionality in Emacs. It uses a separate abbrev table, which is only enabled in auto-correct-mode, and only auto-corrects if a buffer-local predicate returns true.
>
> As with the last two I've submitted today, if no one has any objections, I'll update the copyright and push it to the git repo.
Thanks. Please allow me a few stylistic comments:
> ;;; Commentary:
>
> ;;; Code:
I suggest to say at least a few words about the package and what it
does (or doesn't do) in the Commentary section. "Auto-correct" sounds
very promising, so users might have their expectations too high...
> (defgroup auto-correct nil
> "*Auto correction support."
We no longer use the leading asterisk in doc strings.
> (defun auto-correct-fix-and-add (p)
> "Call `ispell-word', then create an abbrev for it.
> With prefix P, create local abbrev. Otherwise it will
> be global.
Our usual style is
"With a non-nil argument P (interactively, the prefix argument),
create ..."
Also, we use the US English convention of leaving 2 spaces between
sentences.
> Originally pulled from endless parenthesis."
???
> ;; correction was entered by hand.
Comments should preferably be full sentences, so start with a capital
letter.
> ;;;###autoload
> (defun auto-correct-scan-buffer ()
> "Scans current buffer for misspelled words.
Our usual style is to say "Scan", not "Scans".
> When a misspelled word is found, offers to correct and add."
^^^^^^
Resp. "offer". Also, I'd elaborate a bit wrt "and add", as it
otherwise sounds mysterious.
> (defun auto-correct-scan-region (start end)
> (interactive "r")
Interactive functions should have a doc string.
> (defun auto-correct-scan ()
> "Scans the buffer or region."
This doc string sounds too minimal...
Thanks again for working on this.
next prev parent reply other threads:[~2017-08-27 16:34 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-08-27 16:06 [ELPA] New package: Auto Correct Mode Ian Dunn
2017-08-27 16:34 ` Eli Zaretskii [this message]
2017-08-27 18:23 ` Ian Dunn
2017-08-27 18:43 ` Eli Zaretskii
2017-08-27 19:19 ` John Wiegley
2017-08-28 0:29 ` Ian Dunn
2017-09-02 20:58 ` Ian Dunn
2017-09-03 20:48 ` John Wiegley
2017-09-04 13:47 ` Ian Dunn
2017-09-04 22:17 ` Stefan Monnier
2017-09-05 1:04 ` Ian Dunn
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=83shgd3r71.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=dunni@gnu.org \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.