From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "B. T. Raven" Newsgroups: gmane.emacs.help Subject: Re: How to bind -; with a function on windows? Date: Sun, 26 Oct 2008 20:56:53 -0600 Message-ID: References: <0pudnRRrfsDCBJnUnZ2dnUVZ_v7inZ2d@sysmatrix.net> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1225078861 10588 80.91.229.12 (27 Oct 2008 03:41:01 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 27 Oct 2008 03:41:01 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Oct 27 04:42:03 2008 connect(): Connection refused Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1KuIzP-0004lC-QY for geh-help-gnu-emacs@m.gmane.org; Mon, 27 Oct 2008 04:42:00 +0100 Original-Received: from localhost ([127.0.0.1]:59149 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KuIyJ-00044j-QN for geh-help-gnu-emacs@m.gmane.org; Sun, 26 Oct 2008 23:40:51 -0400 Original-Path: news.stanford.edu!headwall.stanford.edu!news.glorb.com!news2!Xl.tags.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!local02.nntp.dca.giganews.com!nntp.sysmatrix.net!news.sysmatrix.net.POSTED!not-for-mail Original-NNTP-Posting-Date: Sun, 26 Oct 2008 21:56:24 -0500 User-Agent: Thunderbird 2.0.0.17 (Windows/20080914) Original-Newsgroups: gnu.emacs.help In-Reply-To: Original-Lines: 60 X-Usenet-Provider: http://www.giganews.com Original-NNTP-Posting-Host: 65.45.140.29 Original-X-Trace: sv3-LBmIEQBxpZI9ZzqaknvoIENc8/HCGjV5qPdD9DoRF01n2A4B9MRLyXdVQEaYd6Bk1hJhLnOZXemj3j8!iCr5JgTHbrD8brrKhR/HXfnemGASCyBLD8LDtz8eJbV0s1P5bD4S9SIbGs/StQOdbb2fEFyxXMol!4pWtZESWzZgsMSpAGBz43qPpYH86lQ== Original-X-Complaints-To: abuse@sysmatrix.net X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly X-Postfilter: 1.3.39 Original-Xref: news.stanford.edu gnu.emacs.help:163839 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:59180 Archived-At: Lennart Borgman wrote: > On Sun, Oct 26, 2008 at 5:23 PM, B. T. Raven wrote: >> anhnmncb wrote: >>> When I type M-x global-set-key RET, then press , the help >>> window pops up and show: >>> >>> runs the command ignore, which is an interactive compiled >>> Lisp function in `subr.el'. >>> >>> It is bound to , , , >>> . >>> >>> I have no chance to press -; to function. Type them in emacs >>> window just produce a ;. >>> >>> >>> >> If you put this in your .emacs: >> >> (setq w32-pass-lwindow-to-system nil >> w32-pass-rwindow-to-system nil >> w32-pass-apps-to-system nil >> w32-lwindow-modifier 'super ;; Left Windows >> w32-rwindow-modifier 'super ;; Right Windows >> w32-apps-modifier 'hyper) ;; App-Menu (key to right of Right >> Windows) >> >> then you will be able to use these bottom row keys as modifiers but you >> still won't be able to bind a function to the bare key (lwindow for >> example). You could however bind the function to Super- [a through z] or >> even combinations of Ctl, Meta, Super, and Hyper: >> >> (global-set-key [(super w)] 'foo) >> >> As Lennart notes there are some combinations that Windows will trap at the >> OS level but some of these are useful. Alt-tab will switch focus between >> emacs and some other app from which you may want to copy-paste for example. > > There are more combinations than Alt-Tab that Windows will trap. For > example on my pc if I do > > (global-set-key [(super ?e)] > (lambda() (interactive) (message "called super E"))) > > This does not work, lwindow+e will still show Windows Explorer. > > That is correct according to MS documentation which says you can not > rely on rebinding lwindow/rwindow without a low level keyboard hook. > Sometimes it works, sometimes it doesn't. > > True if you replace the first "sometimes" with "usually." Super (i.e. windowskey) d, u, f, r (all unshifted) also don't work but the rest of the combinations do. Alt-Tab can't be trapped but it's useful; Alt-F4 is fatal. Ctl-Esc brings up start menu but most if not all other combinations are open for Emacs use. In fact with the hyper key combos (appkey) I got H-whatever undefined with all tested key combos. Ed