<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
  <title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
<br>
<br>
Kurt B. Kaiser wrote:<br>
<blockquote cite="mid87d5lyv8x0.fsf@hydra.bayview.thirdcreek.com"
 type="cite">
  <pre wrap="">Ron MacNeil <a class="moz-txt-link-rfc2396E" href="mailto:ronmac@media.mit.edu">&lt;ronmac@media.mit.edu&gt;</a> writes:

  </pre>
  <blockquote type="cite">
    <pre wrap="">I am using IDLE version 1.1.1 in python 2.4.1 and would like to add
the simplest emacs keybindings like C-p for 'move up one line', C-f
'move forward a character'... C-n 'move down a line'... etc....

Can you please point me to some approach that will do this? I've
tried to edit the existing IDLE keybindings but didn't really get
very far (kept banging into C-f being bound to Find even though I
removed all references to it in config-keys.def.... etc ) I also
have tried using XEmacs and find the lack of color a real pain.
I've searched the web for emacs keybindings for IDLE and found some
interesting pointers but have not got anything to work..
    </pre>
  </blockquote>
  <pre wrap=""><!---->
Simple cursor movement in IDLE is done via the tkinter/Tk library.
IDLE doesn't have virtual events that can be bound to &lt;cursor-left&gt;
and so forth.  So there isn't any simple way to do what you are asking.
  </pre>
</blockquote>
<br>
is there any way to, even in a convoluted way, map "what the left arrow
key does" or "move cursor left one space"&nbsp; to C-b?<br>
<blockquote cite="mid87d5lyv8x0.fsf@hydra.bayview.thirdcreek.com"
 type="cite">
  <pre wrap="">
I think most emacs users these days use the arrow keys, I certainly
do.  Control-f etc. were useful in the olden days when many keyboards
didn't have cursor keys.  Unlike the old Wordstar sexd cursor movement
keys, they aren't particularly convenient bindings.  I'm not going to
type a chord just to move a cursor, especially now that the Control
key is no longer where god intended it to be.
  </pre>
</blockquote>
God would be happy typing on my keyboard... I used keyRemap to put the
control key under my left thumb... <br>
I've gotten very used to moving the cursor with those few commands when
I'm working hard on just a local area of code..<br>
moving my hand away to get to the arrow keys is just not quite it...
anyway... <br>
<blockquote cite="mid87d5lyv8x0.fsf@hydra.bayview.thirdcreek.com"
 type="cite">
  <pre wrap="">
Note that Control-left and Control-right moves by words (in a peculiar,
but useful way).  Control-up and down move by blank-line separated
blocks.
  </pre>
</blockquote>
<blockquote cite="mid87d5lyv8x0.fsf@hydra.bayview.thirdcreek.com"
 type="cite">
  <pre wrap="">
The way to modify IDLE keybindings is to use the Options / Configure
IDLE / Keys dialog.  You "Save as a New Custom Key Set".  This creates
a config-keys.cfg file in your .idlerc directory.  You shouldn't
modify config-keys.def, that's intended to be "factory issue".
  </pre>
</blockquote>
right... I had saved the original config-key.def and now made custom
config-keys.cfg... <br>
thanks much...<br>
cheers, ronmac<br>
</body>
</html>