From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: Where the menu should be appeared when C-mouse-3 is triggered Date: Fri, 20 Jul 2012 07:38:18 -0400 Message-ID: References: <20120719.173253.1324462371913652728.yamato@redhat.com> <20120720.135534.2139116803885399180.yamato@redhat.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1342784328 18380 80.91.229.3 (20 Jul 2012 11:38:48 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 20 Jul 2012 11:38:48 +0000 (UTC) Cc: emacs-devel@gnu.org To: Masatake YAMATO Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Jul 20 13:38:48 2012 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1SsBXj-0001wZ-OO for ged-emacs-devel@m.gmane.org; Fri, 20 Jul 2012 13:38:47 +0200 Original-Received: from localhost ([::1]:46408 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SsBXj-0007Kw-4F for ged-emacs-devel@m.gmane.org; Fri, 20 Jul 2012 07:38:47 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:36939) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SsBXh-0007Kg-5Z for emacs-devel@gnu.org; Fri, 20 Jul 2012 07:38:45 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SsBXd-0004kI-5S for emacs-devel@gnu.org; Fri, 20 Jul 2012 07:38:45 -0400 Original-Received: from chene.dit.umontreal.ca ([132.204.246.20]:53297) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SsBXd-0004kE-1t for emacs-devel@gnu.org; Fri, 20 Jul 2012 07:38:41 -0400 Original-Received: from fmsmemgm.homelinux.net (lechon.iro.umontreal.ca [132.204.27.242]) by chene.dit.umontreal.ca (8.14.1/8.14.1) with ESMTP id q6KBcUlm019608; Fri, 20 Jul 2012 07:38:33 -0400 Original-Received: by fmsmemgm.homelinux.net (Postfix, from userid 20848) id 34015AECB8; Fri, 20 Jul 2012 07:38:18 -0400 (EDT) In-Reply-To: <20120720.135534.2139116803885399180.yamato@redhat.com> (Masatake YAMATO's message of "Fri, 20 Jul 2012 13:55:34 +0900 (JST)") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1.50 (gnu/linux) X-NAI-Spam-Flag: NO X-NAI-Spam-Threshold: 5 X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 1 Rules triggered RV4284=0 X-NAI-Spam-Version: 2.2.0.9309 : core <4284> : streams <787658> : uri <1170196> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 132.204.246.20 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:151779 Archived-At: > With the patch f10 can show the same menu items as > C-mouse-3 shows. The menu is shows at point or mouse > cursor; last-nonmenu-event is referred to decide the > postion. The menu items reflects (current-buffer) when > the menu is shown at point. Sounds good. Installed (except I removed point-pixel-position). > I think a function showing menu at point may be useful > other elisp program, so I introduced `point-pixel-position' > and 'point' constant for POSITION parameter of `popup-menu'. Maybe a better direction is to make popup-menu (and x-popup-menu, ...) accept posn arguments, so you can just use things like (event-end ) or (posn-at-point) to specify where to display it. The docstring of popup-menu seems to indicate that an `event' can be used, but at least in my tests it doesn't seem to work. Could you look at making a patch to do that (i.e. accept a posn, or maybe an event)? Stefan