From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.devel Subject: RE: Usability suggestion : completion for M-: Date: Wed, 9 Apr 2008 14:20:39 -0700 Message-ID: <003901c89a87$8f7cea90$c2b22382@us.oracle.com> References: <87d4oy7oar.fsf@gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1207776181 16500 80.91.229.12 (9 Apr 2008 21:23:01 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 9 Apr 2008 21:23:01 +0000 (UTC) To: "'Paul R'" , "'emacs- devel'" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Apr 09 23:23:33 2008 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1JjhlK-0004ND-14 for ged-emacs-devel@m.gmane.org; Wed, 09 Apr 2008 23:23:22 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Jjhkg-0007tD-BD for ged-emacs-devel@m.gmane.org; Wed, 09 Apr 2008 17:22:42 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Jjhkd-0007sv-3I for emacs-devel@gnu.org; Wed, 09 Apr 2008 17:22:39 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Jjhkb-0007sh-K4 for emacs-devel@gnu.org; Wed, 09 Apr 2008 17:22:38 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Jjhkb-0007se-IL for emacs-devel@gnu.org; Wed, 09 Apr 2008 17:22:37 -0400 Original-Received: from agminet01.oracle.com ([141.146.126.228]) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1Jjhkb-0004zm-57 for emacs-devel@gnu.org; Wed, 09 Apr 2008 17:22:37 -0400 Original-Received: from rgmgw2.us.oracle.com (rgmgw2.us.oracle.com [138.1.186.111]) by agminet01.oracle.com (Switch-3.2.4/Switch-3.1.7) with ESMTP id m39LMWMr032558; Wed, 9 Apr 2008 16:22:32 -0500 Original-Received: from acsmt350.oracle.com (acsmt350.oracle.com [141.146.40.150]) by rgmgw2.us.oracle.com (Switch-3.2.4/Switch-3.2.4) with ESMTP id m39LMVKf004160; Wed, 9 Apr 2008 15:22:31 -0600 Original-Received: from inet-141-146-46-1.oracle.com by acsmt351.oracle.com with ESMTP id 3644958681207776037; Wed, 09 Apr 2008 14:20:37 -0700 Original-Received: from dradamslap1 (/130.35.178.194) by bhmail.oracle.com (Oracle Beehive Gateway v4.0) with ESMTP ; Wed, 09 Apr 2008 14:20:37 -0700 X-Mailer: Microsoft Office Outlook 11 In-Reply-To: <87d4oy7oar.fsf@gmail.com> X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3198 Thread-Index: AciagmpOD4+rMqxqSqOIKFXiIkNS8wAA8bHQ X-Brightmail-Tracker: AAAAAQAAAAI= X-Brightmail-Tracker: AAAAAQAAAAI= X-Whitelist: TRUE X-Whitelist: TRUE X-detected-kernel: by monty-python.gnu.org: Linux 2.4-2.6 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:94812 Archived-At: > * Drew believe that the whole M-: should evolve to something more > like a interactive scratch in the context of current buffer, and > that if TAB does not complete in scratch, it should not complete in > M-: To be specific, I said this: > I would prefer to see M-: take on more of the > character of a pop-up emacs-lisp-mode buffer: > TAB, C-M-q, C-j,..., but with RET still causing > eval... And I'd like to see M-: pretty-print the > result (as in pp-eval-expression) No need to "evolve to something more like" - it's easy enough to do. This is the behavior in Icicles, for instance. (defvar icicle-read-expression-map nil "Icicle mode version of `read-expression-map'. Several Emacs-Lisp mode key bindings are used.") (unless icicle-read-expression-map (let ((map (make-sparse-keymap))) (define-key map "\M-\t" 'lisp-complete-symbol) (define-key map "\t" 'lisp-indent-line) (define-key map "\e\C-q" 'indent-sexp) (define-key map "\e\t" 'lisp-complete-symbol) (define-key map "\e\C-x" 'eval-defun) (define-key map "\e\C-q" 'indent-pp-sexp) ;;(define-key map "\177" 'backward-delete-char-untabify) (set-keymap-parent map minibuffer-local-map) (setq icicle-read-expression-map map))) (defun icicle-pp-eval-expression (expression) ; `M-:' in Icicle mode. "Evaluate an Emacs-Lisp expression and pretty-print its value." (interactive (list (read-from-minibuffer "Eval: " nil icicle-read-expression-map t 'read-expression-history))) (pp-eval-expression expression))