🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.emacs.help
Article #1993

Re: binding cntrl-SPC to set-mark-command

#1993
From: Kevin Gallagher
Date: Fri, 18 Dec 1992 22:22
25 lines
1769 bytes
In article <DLA.92Dec16224504@se05.wg2.waii.com> dla@se05.wg2.waii.com (Doug Acker) writes:
>I'm  trying  to  bind  cntrl-spc  to  set-mark-command  (its  bound to
>self-insert-command right now), so I put this in my .emacs:
>
>(global-set-key "\C-\020" 'set-mark-command)
>
>but this doesn't seem to help .. what am I doing wrong?

Some terminals/keyboards ignore the state of the control key and simply
generate a space character when the spacebar is pressed.  Other
terminals/keyboards generate a NUL character (C-@, x0) when CTRL-Spacebar is
pressed.

It appears that, on your keyboard, CTRL-Spacebar generates a space character.
This means you are out of luck, unless your operating system and/or terminal
drivers support keyboard queries which can report back the state of the
control key on the terminal you are using.  If so, with a little work, you
should be able to hack the source code to GNU Emacs to return a NUL character,
instead of a space, when such an event takes place.

-- 
----------------------------------------------------------------------------
Kevin Gallagher        kgallagh@digi.lonestar.org OR ...!uunet!digi!kgallagh
DSC Communications Corporation   Addr: MS 152, 1000 Coit Rd, Plano, TX 75075
----------------------------------------------------------------------------
Technical Details
Message-ID: <1992Dec18.222242.15043@digi.lonestar.org>
Path: arc1-ca.pugleaf.net!sparky!uunet!cs.utexas.edu!sun-barr!news2me.EBay.Sun.COM!cronkite.Central.Sun.COM!texsun!digi!kgallagh
References: <DLA.92Dec16224504@se05.wg2.waii.com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!cs.utexas.edu!sun-barr!news2me.EBay.Sun.COM!cronkite.Central.Sun.COM!texsun!digi!kgallagh
From: kgallagh@digi.lonestar.org (Kevin Gallagher)
Newsgroups: gnu.emacs.help
Subject: Re: binding cntrl-SPC to set-mark-command
Message-ID: <1992Dec18.222242.15043@digi.lonestar.org>
Date: 18 Dec 92 22:22:42 GMT
References: <DLA.92Dec16224504@se05.wg2.waii.com>
Organization: DSC Communications Corp, Plano, TX
Lines: 25