From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Lennart Borgman Newsgroups: gmane.emacs.devel Subject: Avoiding moving point into minibuffer prompt area Date: Tue, 16 Aug 2005 03:29:11 +0200 Message-ID: <43014167.5000109@student.lu.se> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1124155864 28686 80.91.229.2 (16 Aug 2005 01:31:04 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 16 Aug 2005 01:31:04 +0000 (UTC) Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Aug 16 03:31:01 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1E4qHf-0001b6-Om for ged-emacs-devel@m.gmane.org; Tue, 16 Aug 2005 03:30:31 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1E4qL3-0008Ay-MB for ged-emacs-devel@m.gmane.org; Mon, 15 Aug 2005 21:34:01 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1E4qKj-000898-8B for emacs-devel@gnu.org; Mon, 15 Aug 2005 21:33:41 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1E4qKe-00086R-5U for emacs-devel@gnu.org; Mon, 15 Aug 2005 21:33:37 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1E4qKd-00085y-Vx for emacs-devel@gnu.org; Mon, 15 Aug 2005 21:33:36 -0400 Original-Received: from [81.228.11.98] (helo=pne-smtpout1-sn1.fre.skanova.net) by monty-python.gnu.org with esmtp (Exim 4.34) id 1E4qVm-0007PX-A1 for emacs-devel@gnu.org; Mon, 15 Aug 2005 21:45:06 -0400 Original-Received: from [192.168.123.121] (83.249.204.37) by pne-smtpout1-sn1.fre.skanova.net (7.2.060.1) id 42B813B000876D72 for emacs-devel@gnu.org; Tue, 16 Aug 2005 03:29:11 +0200 User-Agent: Mozilla Thunderbird 1.0.6 (Windows/20050716) X-Accept-Language: en-us, en Original-To: Emacs Devel 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:42093 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:42093 I think it is quite confusing that you can move the point into the prompt area in the minibuffer. Why don't we use something like the code below to avoid this: (defun minibuff-post-command() (when (active-minibuffer-window) (when (< (point) (minibuffer-prompt-end)) (forward-char (- (minibuffer-prompt-end) (point)))))) (add-hook 'post-command-hook 'minibuff-post-command)