From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Masatake YAMATO Newsgroups: gmane.emacs.devel Subject: Re: mode-line highlight Date: Thu, 16 Jun 2005 13:15:56 +0900 (JST) Message-ID: <20050616.131556.188536300.jet@gyve.org> References: NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1118895843 11203 80.91.229.2 (16 Jun 2005 04:24:03 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 16 Jun 2005 04:24:03 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Jun 16 06:24:01 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1Dilur-0003bf-Hx for ged-emacs-devel@m.gmane.org; Thu, 16 Jun 2005 06:23:45 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Dim0C-0007nv-LT for ged-emacs-devel@m.gmane.org; Thu, 16 Jun 2005 00:29:16 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Dilz9-0007If-8U for emacs-devel@gnu.org; Thu, 16 Jun 2005 00:28:12 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Dilyw-0007BT-Gr for emacs-devel@gnu.org; Thu, 16 Jun 2005 00:27:59 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Dilyw-000792-6x for emacs-devel@gnu.org; Thu, 16 Jun 2005 00:27:58 -0400 Original-Received: from [210.130.136.40] (helo=r-maa.spacetown.ne.jp) by monty-python.gnu.org with esmtp (Exim 4.34) id 1Dilux-0001TU-Hq for emacs-devel@gnu.org; Thu, 16 Jun 2005 00:23:52 -0400 Original-Received: from localhost (P061198128244.ppp.prin.ne.jp [61.198.128.244]) by r-maa.spacetown.ne.jp (8.11.6) with ESMTP id j5G4LsX21647; Thu, 16 Jun 2005 13:22:04 +0900 (JST) Original-To: monnier@iro.umontreal.ca In-Reply-To: X-Mailer: Mew version 4.2 on Emacs 22.0.50 / Mule 5.0 (SAKAKI) 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:38932 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:38932 > 1 - move mouse to one of the minor modes names on the mode-line. > press mouse-3 to get a menu of minor modes. > cancel the menu by releasing outside of it (while keeping the mouse > cursor pointing outside of any Emacs window): the mouse-face highlight > will be turned back ON (on the spot where you orignally pressed > mouse-3), even though the mouse is not in that area any more. > I think it is nothing to do with mouse-line. Please eval following code at *scratch*; and do the same on [PRESS ME] on your emacs with Lucid. (easy-menu-define test-menu global-map "Menu for `test-menu'." '("Test" ["Gnus" gnus] ["Grep" grep] )) (let ((b (goto-char (point-max))) (e (progn (insert "[PRESS ME]") (point)))) (put-text-property b e 'mouse-face 'highlight) (put-text-property b e 'local-map (let ((kmap (make-sparse-keymap))) (define-key kmap [down-mouse-3] (lambda () (interactive) (popup-menu test-menu))) kmap))) As Lute reported, emacs with Gtk+ behaves different way. Ignoring this bug, I like the behavior of emacs with lucid; it shows the association between a popup menu and its target item. See smerge's popup menu behavior. Masatake YAMATO