From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Chris Seberino Newsgroups: gmane.emacs.help Subject: Re: Trouble binding Alt *by itself* to the execute-extended-command...(Alt-x and ESC-x work fine.) Date: Sat, 6 Jul 2013 22:08:07 -0700 (PDT) Message-ID: <85b6caa3-a637-401d-8a00-e49868ea8832@googlegroups.com> References: <6a969c8d-e606-4143-afd1-83ee32c82aeb@googlegroups.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 X-Trace: ger.gmane.org 1373173817 19744 80.91.229.3 (7 Jul 2013 05:10:17 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 7 Jul 2013 05:10:17 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sun Jul 07 07:10:17 2013 Return-path: Envelope-to: geh-help-gnu-emacs@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 1UvhEm-0002NO-F7 for geh-help-gnu-emacs@m.gmane.org; Sun, 07 Jul 2013 07:10:16 +0200 Original-Received: from localhost ([::1]:38258 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UvhEm-0005RN-0K for geh-help-gnu-emacs@m.gmane.org; Sun, 07 Jul 2013 01:10:16 -0400 X-Received: by 10.66.161.201 with SMTP id xu9mr1657921pab.3.1373173688110; Sat, 06 Jul 2013 22:08:08 -0700 (PDT) X-Received: by 10.49.62.3 with SMTP id u3mr368904qer.26.1373173687685; Sat, 06 Jul 2013 22:08:07 -0700 (PDT) Original-Path: usenet.stanford.edu!qx7no21341163pbc.1!news-out.google.com!b2ni49157pby.1!nntp.google.com!qx7no21341159pbc.1!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help In-Reply-To: <6a969c8d-e606-4143-afd1-83ee32c82aeb@googlegroups.com> Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=74.194.237.26; posting-account=VkuUtQkAAADKqMjRUmZTNs7a8uCSNNy2 Original-NNTP-Posting-Host: 74.194.237.26 User-Agent: G2/1.0 Injection-Date: Sun, 07 Jul 2013 05:08:08 +0000 Original-Xref: usenet.stanford.edu gnu.emacs.help:199731 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 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-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:91999 Archived-At: Thank you all for your help. I finally got it. In Ubuntu 12.04.2 LTS with Emacs 23.3.1 I did the following: 1. Remap Alt keys to the menu key... xmodmap -e "keycode 64 = Menu" xmodmap -e "keycode 108 = Menu" 2. Store that permanently... xmodmap -pke > ~/.Xmodmap echo "xmodmap .Xmodmap in" > ~/.xinitrc ... That should work since the menu key runs execute-extended-command already. I personally wanted to add some stuff before and after running execute-extended-command so I added this to my .emacs ... (global-set-key (kbd "") (lambda () (interactive) ....extra commands here... (execute-extended-command t) ....extra commands here...)) It seems there is almost nothing Emacs can't do!