all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Herman@debbugs.gnu.org, Géza <geza.herman@gmail.com>
To: 67514@debbugs.gnu.org
Subject: bug#67514: 30.0.50; completion preview symbol length calculation should use point
Date: Tue, 28 Nov 2023 21:39:49 +0100	[thread overview]
Message-ID: <87y1ehfw8a.fsf@gmail.com> (raw)


I checked out completion-preview, and so far I like it.  There is a
thing which maybe can be improved (so this is not a bug report, just a
suggestion): it's how completion-preview-require-minimum-symbol-length
calculates the length.  Currently it just returns the length of the
symbol under the cursor.  I think it would be better to use the length
of the part that actually will be used for completion, because if the
point is inside a word, then it should only consider the part between
the symbol start end the point.

I mean, completion-preview-require-minimum-symbol-length should look
something like this:

(let ((bounds (bounds-of-thing-at-point 'symbol)))
      (and bounds (<= completion-preview-minimum-symbol-length
                      (- (point) (car bounds)))))





             reply	other threads:[~2023-11-28 20:39 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-28 20:39 Herman, Géza [this message]
2023-11-28 21:46 ` bug#67514: 30.0.50; completion preview symbol length calculation should use point Eshel Yaron via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-11-28 23:17   ` Herman, Géza
2023-11-29  8:55     ` Eshel Yaron via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-11-29  9:06       ` Herman, Géza
2023-11-29 21:26         ` Eshel Yaron via Bug reports for GNU Emacs, the Swiss army knife of text editors

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=87y1ehfw8a.fsf@gmail.com \
    --to=herman@debbugs.gnu.org \
    --cc=67514@debbugs.gnu.org \
    --cc=geza.herman@gmail.com \
    /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.