On 10/27/07, Boyd Waters <[EMAIL PROTECTED]> wrote:
> OK, thanks... I'll try to put something in ipy_defaults.py
>
> I'm trying to come up to speed on the new style configuration. I'll
> try looking through Trac for more info as well.

Honestly, this is so important that I'd rather have it in the core so
it works for any user, without bugging them about updating their
config setup or having to think at all.  If they have requested
readline support, then it should just work.  We already have
platform-specific code to work around a  things in Windows, having a
little bit of Leopard support doesn't bother me one bit.

Have a look at the attached patch, and if something like that works
well, we can easily just drop it in.

Cheers,

f
Index: IPython/iplib.py
===================================================================
--- IPython/iplib.py	(revision 2848)
+++ IPython/iplib.py	(working copy)
@@ -1320,6 +1320,13 @@
             else:
                 self.readline_startup_hook = readline.set_startup_hook
 
+            # OSX Leopard ships with Python 2.5 and full readline support, but
+            # using EditLine under the hood.  This requires that tab completion
+            # be enabled via a special call, as indicated in this thread:
+            # http://lists.ipython.scipy.org/pipermail/ipython-dev/2007-October/003290.html
+            if sys.platform.startswith('darwin'):
+                readline.parse_and_bind("bind ^I rl_complete")
+
             # Load user's initrc file (readline config)
             inputrc_name = os.environ.get('INPUTRC')
             if inputrc_name is None:
_______________________________________________
Pythonmac-SIG maillist  -  Pythonmac-SIG@python.org
http://mail.python.org/mailman/listinfo/pythonmac-sig

Reply via email to