From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: "N. Jackson" Newsgroups: gmane.emacs.help Subject: Pop up context menu (at point) with key rather than mouse Date: Fri, 09 Nov 2018 14:19:50 -0500 Message-ID: <87sh0akqi1.fsf@moondust.localdomain> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: blaine.gmane.org 1541791108 10277 195.159.176.226 (9 Nov 2018 19:18:28 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 9 Nov 2018 19:18:28 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Nov 09 20:18:24 2018 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gLCIS-0002Xy-2o for geh-help-gnu-emacs@m.gmane.org; Fri, 09 Nov 2018 20:18:24 +0100 Original-Received: from localhost ([::1]:35649 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gLCKY-0002IF-G1 for geh-help-gnu-emacs@m.gmane.org; Fri, 09 Nov 2018 14:20:34 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:42467) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gLCK8-0002IA-DT for help-gnu-emacs@gnu.org; Fri, 09 Nov 2018 14:20:09 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gLCK4-0001Tb-EO for help-gnu-emacs@gnu.org; Fri, 09 Nov 2018 14:20:08 -0500 Original-Received: from [195.159.176.226] (port=48132 helo=blaine.gmane.org) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gLCK4-0001Sj-6x for help-gnu-emacs@gnu.org; Fri, 09 Nov 2018 14:20:04 -0500 Original-Received: from list by blaine.gmane.org with local (Exim 4.84_2) (envelope-from ) id 1gLCHr-0001eB-Vx for help-gnu-emacs@gnu.org; Fri, 09 Nov 2018 20:17:47 +0100 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 35 Original-X-Complaints-To: usenet@blaine.gmane.org Cancel-Lock: sha1:MUiB8QheAX1bTcGa6wS8islxB7w= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 195.159.176.226 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.org gmane.emacs.help:118629 Archived-At: I would like to configure my Emacs so that when I press the key on my keyboard, a pop-up menu is displayed. I think I want this to be same pop-up menu that is displayed when I press C-mouse-3. Although I am not quite clear how this menu differs from the one that pops up when I press F10 -- sometimes they are the same, sometimes they are different. Possibly what I really want is the pop-up menu that appears when I press just mouse-3, although that doesn't seem to pop up a menu at the moment (rather is seems to select random-seeming text) but I think it used to give a pop-up menu -- or maybe it just does in certain contexts. Yes. It works on "buttons" in the Gnus Article buffer for example. In any case, I want the menu to pop up in the context of point, not in the context of the mouse pointer. Initially I tried (define-key key-translation-map (kbd "") (kbd "")) but obviously that is too naïve, as clearly I'm going to need to do something about making the menu's position be the position of point. I think what I need to move forward on this, is to know what function is run to display the menus popped up by C-mouse-3 (and by mouse-3 (when it pops up a menu at all)), I suppose I can find these functions by running Emacs under GDB, popping up a menu, halting Emacs in GDB, and displaying a backtrace, although I feel there must be a much easier way. Does anyone have any information that might help with this? N.