unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* Mac Apple/Command key on linux (or even just "Command-key in emacs on linux")
@ 2007-12-26 19:57 Livin Stephen
  2007-12-27 12:48 ` Xah Lee
  2007-12-27 15:57 ` Peter Dyballa
  0 siblings, 2 replies; 6+ messages in thread
From: Livin Stephen @ 2007-12-26 19:57 UTC (permalink / raw)
  To: help-gnu-emacs

I own and use a PowerBook G4.

Also, I'm an emacs user, and to save my pinky a lot of grief I use the
Command key () as the Ctrl key within emacs. This works fine when
using my local (powerbook) installation.

However, for work, I need to connect to linux servers using VNC. The
emacs installation I have running at work (being on linux) doesn't see/
recognise the command-key.

I'd like to know how the keyboard's Command Key can be mapped to Ctrl
on linux. Either using the linux OS or even just variables/options
within emacs-on-linux.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Mac Apple/Command key on linux (or even just "Command-key in  emacs on linux")
  2007-12-26 19:57 Mac Apple/Command key on linux (or even just "Command-key in emacs on linux") Livin Stephen
@ 2007-12-27 12:48 ` Xah Lee
  2007-12-27 15:57 ` Peter Dyballa
  1 sibling, 0 replies; 6+ messages in thread
From: Xah Lee @ 2007-12-27 12:48 UTC (permalink / raw)
  To: help-gnu-emacs

if i understand you correctly... you want to use your mac to connect
to a remote linux server (using the local terminal app), and invoke
the remote emacs in the terminal?

in that case, i don't think remaping keys on the linux or rebinding
keys within the remote emacs is what you want.

i think to achieve what you want, is probably to remap the key on your
mac or terminal app.

I have written several articles on this... i think it'll be helpful:

★ How To Avoid The Emacs Pinky Problem
http://xahlee.org/emacs/emacs_pinky.html

★ A Ergonomic Keyboard Shortcut Layout
http://xahlee.org/emacs/ergonomic_emacs_keybinding.html

The above 2 are general advices. Following are some essays that
address how to remap keys:

★ Mac OS X Keybinding
 http://xahlee.org/emacs/osx_keybinding.html
(this shows you the system-wide general mechanism on remaping keys on
mac os x.)

★ How to Define Keyboard Shortcuts in Emacs
http://xahlee.org/emacs/keyboard_shortcuts.html

★ How to Swap Modifier Keys on OS X
http://xahlee.org/emacs/osx_swapping_modifier_keys.html

I think the last one is really what you need.

But if you really want is swapping modifier keys on a linux machine,
your solution is xmodmap. I'm guessing there's GUI buildin in most
linuxes that does this... but if not, you can “man xmodmap” or see a
sample file here
http://xahlee.org/PageTwo_dir/Personal_dir/dvorakKeymap.txt

there are lots resoures on the web about how to use xmodmap.
e.g. http://www.emacswiki.org/cgi-bin/wiki/MovingTheCtrlKey

  Xah
  xah@xahlee.org
∑ http://xahlee.org/

On Dec 26, 11:57 am, Livin Stephen <livin.step...@gmail.com> wrote:
> I own and use a PowerBook G4.
>
> Also, I'm an emacs user, and to save my pinky a lot of grief I use the
> Command key () as the Ctrl key within emacs. This works fine when
> using my local (powerbook) installation.
>
> However, for work, I need to connect to linux servers using VNC. The
> emacs installation I have running at work (being on linux) doesn't see/
> recognise the command-key.
>
> I'd like to know how the keyboard's Command Key can be mapped to Ctrl
> on linux. Either using the linux OS or even just variables/options
> within emacs-on-linux.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Mac Apple/Command key on linux (or even just "Command-key in emacs on linux")
  2007-12-26 19:57 Mac Apple/Command key on linux (or even just "Command-key in emacs on linux") Livin Stephen
  2007-12-27 12:48 ` Xah Lee
@ 2007-12-27 15:57 ` Peter Dyballa
  2007-12-27 19:42   ` Livin Stephen Sharma
  1 sibling, 1 reply; 6+ messages in thread
From: Peter Dyballa @ 2007-12-27 15:57 UTC (permalink / raw)
  To: Livin Stephen; +Cc: help-gnu-emacs


Am 26.12.2007 um 20:57 schrieb Livin Stephen:

> I'd like to know how the keyboard's Command Key can be mapped to Ctrl
> on linux. Either using the linux OS or even just variables/options
> within emacs-on-linux.


Are you using X11 or some terminal emulation to connect to the Linux  
side from your Mac?

--
Greetings

   Pete

They're putting dimes in the hole in my head to see the change in me.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Mac Apple/Command key on linux (or even just "Command-key in emacs on linux")
  2007-12-27 15:57 ` Peter Dyballa
@ 2007-12-27 19:42   ` Livin Stephen Sharma
  2007-12-28  1:06     ` David Brodbeck
       [not found]     ` <mailman.5446.1198804015.18990.help-gnu-emacs@gnu.org>
  0 siblings, 2 replies; 6+ messages in thread
From: Livin Stephen Sharma @ 2007-12-27 19:42 UTC (permalink / raw)
  To: Peter Dyballa; +Cc: help-gnu-emacs


[-- Attachment #1.1: Type: text/plain, Size: 526 bytes --]

On 27/12/2007, Peter Dyballa <Peter_Dyballa@web.de> wrote:
>
>
> Am 26.12.2007 um 20:57 schrieb Livin Stephen:
>
> > I'd like to know how the keyboard's Command Key can be mapped to Ctrl
> > on linux.
> Are you using X11 or some terminal emulation to connect to the Linux
> side from your Mac?


I connect using VNC - kinda like Remote Desktop, I guess?
http://www.realvnc.com/vnc/index.html
http://sourceforge.net/projects/cotvnc/

"... A VNC client allows one to display and interact with a remote computer
screen. ..."


I

[-- Attachment #1.2: Type: text/html, Size: 1362 bytes --]

[-- Attachment #2: Type: text/plain, Size: 152 bytes --]

_______________________________________________
help-gnu-emacs mailing list
help-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/help-gnu-emacs

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Mac Apple/Command key on linux (or even just "Command-key in emacs on linux")
  2007-12-27 19:42   ` Livin Stephen Sharma
@ 2007-12-28  1:06     ` David Brodbeck
       [not found]     ` <mailman.5446.1198804015.18990.help-gnu-emacs@gnu.org>
  1 sibling, 0 replies; 6+ messages in thread
From: David Brodbeck @ 2007-12-28  1:06 UTC (permalink / raw)
  To: emacs list


[-- Attachment #1.1: Type: text/plain, Size: 670 bytes --]


On Dec 27, 2007, at 11:42 AM, Livin Stephen Sharma wrote:

>
>
> On 27/12/2007, Peter Dyballa <Peter_Dyballa@web.de> wrote:
>
> Am 26.12.2007 um 20:57 schrieb Livin Stephen:
>
> > I'd like to know how the keyboard's Command Key can be mapped to  
> Ctrl
> > on linux.
> Are you using X11 or some terminal emulation to connect to the Linux
> side from your Mac?
>
> I connect using VNC - kinda like Remote Desktop, I guess?
> http://www.realvnc.com/vnc/index.html
> http://sourceforge.net/projects/cotvnc/
>
> "... A VNC client allows one to display and interact with a remote  
> computer screen. ... "

VNC emulates an X server, so xmodmap is probably what you want.


[-- Attachment #1.2: Type: text/html, Size: 1717 bytes --]

[-- Attachment #2: Type: text/plain, Size: 152 bytes --]

_______________________________________________
help-gnu-emacs mailing list
help-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/help-gnu-emacs

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Mac Apple/Command key on linux (or even just "Command-key in  emacs on linux")
       [not found]     ` <mailman.5446.1198804015.18990.help-gnu-emacs@gnu.org>
@ 2007-12-29 14:46       ` deprecated
  0 siblings, 0 replies; 6+ messages in thread
From: deprecated @ 2007-12-29 14:46 UTC (permalink / raw)
  To: help-gnu-emacs

On Dec 27, 7:06 pm, David Brodbeck <bro...@u.washington.edu> wrote:
> On Dec 27, 2007, at 11:42 AM, Livin Stephen Sharma wrote:
> > On 27/12/2007, Peter Dyballa <Peter_Dyba...@web.de> wrote:
> > Am 26.12.2007 um 20:57 schrieb Livin Stephen:
> > > I'd like to know how the keyboard's Command Key can be mapped to  
> > Ctrl
> > > on linux.
> > Are you using X11 or some terminal emulation to connect to the Linux
> > side from your Mac?
>
> > I connect using VNC - kinda like Remote Desktop, I guess?
> >http://www.realvnc.com/vnc/index.html
> >http://sourceforge.net/projects/cotvnc/
>
> > "... A VNC client allows one to display and interact with a remote  
> > computer screen. ... "
>
> VNC emulates an X server, so xmodmap is probably what you want.

And to find out which keys to map, you can use "xev". Run it on your
linux server while connected via vnc. It gives you a little window
that will register all your keypresses and tell you the relevant
keysym and keycode.

However, I'm not sure this will be any help. With the VNC client that
I use (Chicken of the VNC), both the Command and Option key on my
powerbook seem to generate the same key on the linux side - keycode 64
(keysym 0xffe9 Alt_L). This means that if you bind the Command key to
Ctrl in emacs, you won't be able to use the Option key for meta.
Perhaps you could bind the Ctrl key to meta. I haven't found any way
of fixing this with Chicken of the VNC, but other vnc clients might be
better in this regard.

Personally, I avoid "emacs pinky syndrome" by using my thumb
instead...

Cheers

Will

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2007-12-29 14:46 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-12-26 19:57 Mac Apple/Command key on linux (or even just "Command-key in emacs on linux") Livin Stephen
2007-12-27 12:48 ` Xah Lee
2007-12-27 15:57 ` Peter Dyballa
2007-12-27 19:42   ` Livin Stephen Sharma
2007-12-28  1:06     ` David Brodbeck
     [not found]     ` <mailman.5446.1198804015.18990.help-gnu-emacs@gnu.org>
2007-12-29 14:46       ` deprecated

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).