all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Mathias Dahl <mathias.dahl@gmail.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: emacs-devel@gnu.org
Subject: Re: [PATCH] Add abbrev suggestions
Date: Thu, 13 Aug 2020 16:29:57 +0200	[thread overview]
Message-ID: <CABrcCQ7Fm1N23iSM0J5=VJ7asNPx80h-K94MEcDyAwAPJ2tTdg@mail.gmail.com> (raw)
In-Reply-To: <838seimytk.fsf@gnu.org>

[-- Attachment #1: Type: text/plain, Size: 2372 bytes --]

> > No, I'm not. In fact, it was not the default when I started
> > working on this, but Stefan suggested that it might be a good
> > default. Now we're me and you against him, I guess... :)

> Let's start with having it opt-in.  We can later see if it is
> popular enough to become the default.

Fine by me.

> How about the below?

> Return non-nil if an abbrev in EXPANSION provides significant
> savings.

Hey, that's cheating! :)

I prepared a new version myself too. Will see which one I select when
I send a new patch...

> > Should I include those changes in the same patch and resend
> > that when done?

> Yes, please.

Alrighty then!

Thanks!

/Mathias


On Thu, Aug 13, 2020 at 3:59 PM Eli Zaretskii <eliz@gnu.org> wrote:

> > From: Mathias Dahl <mathias.dahl@gmail.com>
> > Date: Wed, 12 Aug 2020 00:16:33 +0200
> > Cc: emacs-devel@gnu.org
> >
> > > Are you sure it is a good idea to make this non-nil by default?
> > > Wouldn't some users consider these suggestions an annoyance?
> >
> > No, I'm not. In fact, it was not the default when I started working on
> > this, but Stefan suggested that it might be a good default. Now we're
> > me and you against him, I guess... :)
>
> Let's start with having it opt-in.  We can later see if it is popular
> enough to become the default.
>
> > > > +(defun abbrev--suggest-above-threshold (expansion)
> > > > +    "Return t if we are above the threshold.
> > >
> > > Who is "we" in this context?  This should be explained.
> >
> > I know, I was not happy when I wrote that. "we", here, is something
> > like "the difference in length between what the user typed and the
> > abbrev that we found." I guess I could not find a good way to keep the
> > first sentence of the docstring short, so I opted for the fuzzy "we"
> > expression...
>
> How about the below?
>
>   Return non-nil if an abbrev in EXPANSION provides significant savings.
>
> > > > +EXPANSION is a cons cell where the car is the expansion and the
> > > > +cdr is the abbrev."
> > >
> > > Our style is to include the arguments in the first sentence of the doc
> > > string.
> >
> > I know. Frankly I don't know if I can come up with a suggestion that
> > combines that together with having a relatively short first
> > sentence...
>
> See above.
>
> > Should I include those changes in the same patch and resend
> > that when done?
>
> Yes, please.
>

[-- Attachment #2: Type: text/html, Size: 3294 bytes --]

  reply	other threads:[~2020-08-13 14:29 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-05 23:40 [PATCH] Add abbrev suggestions Mathias Dahl
2020-07-19 17:40 ` Mathias Dahl
2020-07-19 19:01   ` Eli Zaretskii
2020-07-25  8:12     ` Eli Zaretskii
2020-08-11 22:16       ` Mathias Dahl
2020-08-13 13:59         ` Eli Zaretskii
2020-08-13 14:29           ` Mathias Dahl [this message]
2020-09-14 22:04             ` Mathias Dahl
2020-09-15  6:20               ` Andreas Röhler
2020-09-18  8:39                 ` Mathias Dahl
2020-09-15  8:16               ` Robert Pluim
2020-09-18  8:40                 ` Mathias Dahl
2020-09-24 20:02                   ` Mathias Dahl
2020-09-25  8:09                     ` Robert Pluim
2020-09-25 20:42                       ` Mathias Dahl
2020-09-26 14:19                         ` Robert Pluim
2020-09-26 20:56                           ` Mathias Dahl
2020-09-26 22:21                             ` Stefan Monnier
2020-09-27  6:12                             ` Eli Zaretskii

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='CABrcCQ7Fm1N23iSM0J5=VJ7asNPx80h-K94MEcDyAwAPJ2tTdg@mail.gmail.com' \
    --to=mathias.dahl@gmail.com \
    --cc=eliz@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.