From: Lluis <xscript@gmx.net>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: emacs-devel@gnu.org
Subject: Re: Completions in Semantic
Date: Tue, 27 Oct 2009 22:21:18 +0100 [thread overview]
Message-ID: <20091027212118.GA25239@ginnungagap.pc.ac.upc.edu> (raw)
In-Reply-To: <jwviqe7kxkn.fsf-monnier+emacs@gnu.org>
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset=utf-8, Size: 3781 bytes --]
Sorry for the delay and the scarce response... too much work.
El Thu, Oct 22, 2009 at 04:12:09PM -0400, Stefan Monnier ens deleità amb les següents paraules:
> > I don't know about the features of current code, but I miss some
> > features on some (if not all) the completion interfaces I've tested.
> > So here's a list of (my) desired features (all of which should be
> > configurable by the user):
>
> Sounds interesting, but I must be missing some context because there's
> a lot of references I don't understand. Could you expand on them?
Sure.
> > - symbol name
> > Of course, this is what already provides every completion UI
>
> No idea what you're talking about here.
>
> > - extra information
> > This can be filled ub with symbol "metadata". Which metadata
> > appears on the completion UI should be configurable by the user:
> > - return type
> > - arguments (type and/or name)
> > - definition location (aka file)
> > - short documentation
> > - long documentation
> > All this metadata should be located anywhere around the symbol name
> > and/or the minibuffer (e.g., I think company-mode shows short
> > documentation on minibuffer, until user presses F1, when full
> > documentation is shown. Some metadata might be shown in the
> > minibuffer after completion selection (e.g., prototype).
>
> Oh... wait, are you talking specifically about completion in code
> buffers, so "symbol name" above referred to the ability to complete an
> identifier?
That's right.
> As for this "extra info", I see what you mean, but usually completion
> involves several potential candidates, so listing them all plus all
> their info would take way too much space in general (if not, then
> something like completion-annotate-function should work).
What I described is similar to `completion-annotate-function', but more
flexible (prefixed in the symbol/identifier, postfixed; some in overlay, some in
minibuffer, etc).
> So usually this extra info is provided outside of the completion functionality
> (e.g. via eldoc-mode or something similar). But, yes, I'd like to extend the
> *Completions* buffer so that you could ask for more info (either on all
> entries, or just on one at a time).
The key here is that completions do not necessarily have to go (only) into the
*Completions* buffer.
> > - result narrowing
> > A-la company-mode.
>
> No idea to what this is referring.
Company-mode provides a binding that, given the current table of possible
completions, the user can narrow it through various mechanisms (e.g., regexps).
> > - argument placeholders So that argument type and/or name is shown as
> > placeholders, such that the user simply TABs (or whatever) to fill-in
> > the blanks.
>
> Idem. Unless you mean something like skeletons/templates, but then
> I fail to see the connection with completion.
Completing a symbol triggers an arbitrary function, which could, for example:
- show symbol definition
- show short and/or extended documentation for symbol
- insert skeleton/template-like symbol definition (such that user simply
tabs to sellect next argument placeholder, which initially contains
argument name and/or type).
This could be achieved if completions where "complex objects", so each could
describe what/where to show on the specific current completion UI, a "hover"
callback (e.g. show short doc or symbol signature on minibuffer), and a
selection callback (e.g., same possibilities as hover, plus the skeleton thing).
Read you,
Lluis
--
"And it's much the same thing with knowledge, for whenever you learn
something new, the whole world becomes that much richer."
-- The Princess of Pure Reason, as told by Norton Juster in The Phantom
Tollbooth
next prev parent reply other threads:[~2009-10-27 21:21 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-10-18 23:00 Completions in Semantic Chong Yidong
2009-10-18 23:55 ` Miles Bader
2009-10-19 3:50 ` Eric M. Ludlam
2009-10-19 13:48 ` Stefan Monnier
2009-10-19 16:26 ` Eric M. Ludlam
2009-10-19 18:29 ` Stefan Monnier
2009-10-19 19:33 ` Eric M. Ludlam
2009-10-19 20:06 ` Stefan Monnier
2009-10-19 22:17 ` Eric M. Ludlam
2009-10-20 0:07 ` Lennart Borgman
2009-10-30 21:17 ` Toby Cubitt
2009-10-30 21:37 ` Lennart Borgman
2009-10-20 0:14 ` Stefan Monnier
2009-10-20 20:20 ` Eric M. Ludlam
2009-10-21 10:58 ` Lluis
2009-10-21 12:35 ` Eric M. Ludlam
2009-10-21 13:28 ` Lluis
2009-10-21 17:35 ` Eric M. Ludlam
2009-10-22 20:12 ` Stefan Monnier
2009-10-27 21:21 ` Lluis [this message]
2009-10-28 0:56 ` Stefan Monnier
2009-10-28 2:25 ` Eric M. Ludlam
2009-10-28 3:23 ` Stefan Monnier
2009-10-29 14:38 ` Lluis
2009-10-31 20:18 ` Stefan Monnier
2009-11-01 16:01 ` Lluís
2009-11-02 6:12 ` Stefan Monnier
2009-11-02 12:13 ` Eric M. Ludlam
2009-10-22 20:00 ` Stefan Monnier
2009-10-19 23:52 ` Eric M. Ludlam
2009-10-21 14:07 ` Chong Yidong
2009-10-21 16:10 ` Eric M. Ludlam
2009-10-23 1:01 ` Chong Yidong
2009-10-23 1:28 ` Eric M. Ludlam
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20091027212118.GA25239@ginnungagap.pc.ac.upc.edu \
--to=xscript@gmx.net \
--cc=emacs-devel@gnu.org \
--cc=monnier@iro.umontreal.ca \
/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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).