all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#12690: 24.2; [FEATURE REQUEST] Make :annotation-function more flexible
@ 2012-10-20  8:26 Leo
  2012-10-23  1:51 ` Stefan Monnier
  0 siblings, 1 reply; 2+ messages in thread
From: Leo @ 2012-10-20  8:26 UTC (permalink / raw)
  To: 12690

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

In a modern decent IDE, completion annotation is a great help in finding
the right completion candidate especially when the collection is large.
See the attached screenshot, it uses color and letter to help users
identify the type of completion they are looking for. Emacs is rather
limited in this regard. It seems something can be achieved by allowing
:annotation-function to return the WHOLE thing to be displayed in the
*Completions* buffer.

Leo

[-- Attachment #2: xcode-completion-annotations.png --]
[-- Type: image/png, Size: 184629 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* bug#12690: 24.2; [FEATURE REQUEST] Make :annotation-function more flexible
  2012-10-20  8:26 bug#12690: 24.2; [FEATURE REQUEST] Make :annotation-function more flexible Leo
@ 2012-10-23  1:51 ` Stefan Monnier
  0 siblings, 0 replies; 2+ messages in thread
From: Stefan Monnier @ 2012-10-23  1:51 UTC (permalink / raw)
  To: Leo; +Cc: 12690

severity 12690 wishlist
thanks

> In a modern decent IDE, completion annotation is a great help in finding
> the right completion candidate especially when the collection is large.
> See the attached screenshot, it uses color and letter to help users
> identify the type of completion they are looking for. Emacs is rather
> limited in this regard. It seems something can be achieved by allowing
> :annotation-function to return the WHOLE thing to be displayed in the
> *Completions* buffer.

I agree we need to make it possible to provide a richer display.
E.g. popup-help on each entry, or even more extended help in *Help* by
pressing a particular key.
In your image you show text prepended before each entry as well, which
can be also be useful.  But note that prepending text requires accessing
the complete completion list, so as to know how much space to leave to
align all entries.
Furthermore, how to display such text might depend on the UI you use
(e.g. you can prepend the text without affecting the actual textual
content of the completion buffer with an overlay or text-properties,
but that won't work if the completion is displayed as a GUI menu, so
I think we'd need the new annotation function to return a "high-level"
description so the UI code can then choose which trick to use to display
that data).


        Stefan





^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-10-23  1:51 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-10-20  8:26 bug#12690: 24.2; [FEATURE REQUEST] Make :annotation-function more flexible Leo
2012-10-23  1:51 ` Stefan Monnier

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.