From: Glenn Morris <rgm@gnu.org>
To: alinsoar@voila.fr
Cc: "Emacs Dev \[emacs-devel\]" <emacs-devel@gnu.org>
Subject: Re: partial-completion-mode and mouse selection
Date: Thu, 22 Mar 2007 17:56:33 -0400 [thread overview]
Message-ID: <3r6rh9c32.fsf@fencepost.gnu.org> (raw)
In-Reply-To: <20455115.241481174582123314.JavaMail.www@wwinf4103> (A. Soare's message of "Thu, 22 Mar 2007 17:48:43 +0100 (CET)")
A Soare wrote:
> 1. partial completion mode started.
>
> 2. M-:
>
> Eval: (n-f <M-TAB>
>
> Select using left mouse button one choice.
This bug report is still somewhat vague, but I see your point.
Please test how the following patch affects partial completion in
general.
*** complete.el 21 Mar 2007 19:23:12 -0000 1.67
--- complete.el 22 Mar 2007 21:53:28 -0000
***************
*** 743,755 ****
(and completion-auto-help
(eq last-command this-command))
(eq mode 'help))
(with-output-to-temp-buffer "*Completions*"
(display-completion-list (sort helpposs 'string-lessp))
(with-current-buffer standard-output
;; Record which part of the buffer we are completing
;; so that choosing a completion from the list
;; knows how much old text to replace.
! (setq completion-base-size dirlength)))
(PC-temp-minibuffer-message " [Next char not unique]"))
nil)))))
--- 743,758 ----
(and completion-auto-help
(eq last-command this-command))
(eq mode 'help))
+ (let ((width (minibuffer-prompt-width)))
(with-output-to-temp-buffer "*Completions*"
(display-completion-list (sort helpposs 'string-lessp))
(with-current-buffer standard-output
;; Record which part of the buffer we are completing
;; so that choosing a completion from the list
;; knows how much old text to replace.
! (setq completion-base-size (if dirname
! dirlength
! (- beg 1 width))))))
(PC-temp-minibuffer-message " [Next char not unique]"))
nil)))))
***************
*** 799,804 ****
--- 802,808 ----
(setq quit-flag nil
unread-command-events '(7))))))))
+ (defvar PC-lisp-complete-end nil)
(defun PC-lisp-complete-symbol ()
"Perform completion on Lisp symbol preceding point.
***************
*** 825,831 ****
(or (boundp sym) (fboundp sym)
(symbol-plist sym))))))
(PC-not-minibuffer t))
! (PC-do-completion nil beg end)))
(defun PC-complete-as-file-name ()
"Perform completion on file names preceding point.
--- 829,838 ----
(or (boundp sym) (fboundp sym)
(symbol-plist sym))))))
(PC-not-minibuffer t))
! (if (equal last-command 'PC-lisp-complete-symbol)
! (PC-do-completion nil beg PC-lisp-complete-end)
! (setq PC-lisp-complete-end (point-marker))
! (PC-do-completion nil beg end))))
(defun PC-complete-as-file-name ()
"Perform completion on file names preceding point.
next prev parent reply other threads:[~2007-03-22 21:56 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-03-22 16:48 partial-completion-mode and mouse selection A Soare
2007-03-22 21:56 ` Glenn Morris [this message]
2007-03-23 16:48 ` Stefan Monnier
2007-03-27 3:16 ` Glenn Morris
-- strict thread matches above, loose matches on Subject: below --
2007-03-23 12:57 A Soare
2007-03-23 10:15 A Soare
2007-03-22 16:29 A Soare
2007-03-22 16:12 A Soare
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=3r6rh9c32.fsf@fencepost.gnu.org \
--to=rgm@gnu.org \
--cc=alinsoar@voila.fr \
--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 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).