From 4199cd45d4779bd3053ba8b4ded9303816d42c4a Mon Sep 17 00:00:00 2001 From: jstenar <> Date: Sat, 21 Apr 2007 20:26:24 +0000 Subject: [PATCH] pyreadline: updates to documentation and release.py. Change in how keyboard_interrupts propagates in ironpython, still some work is left to get the same traceback on pressing ctrl-c as a plain ironpython without pyreadline installed. --- pyreadline/console/ironpython_console.py | 5 +---- pyreadline/modes/basemode.py | 3 ++- pyreadline/release.py | 19 ++++++++++++------- 3 files changed, 15 insertions(+), 12 deletions(-) diff --git a/pyreadline/console/ironpython_console.py b/pyreadline/console/ironpython_console.py index 1669b63..d8c048a 100644 --- a/pyreadline/console/ironpython_console.py +++ b/pyreadline/console/ironpython_console.py @@ -305,10 +305,7 @@ class Console(object): '''Return next key press event from the queue, ignoring others.''' ck=System.ConsoleKey while 1: - try: - e = System.Console.ReadKey(True) - except KeyboardInterrupt: - return CTRL_C_EVENT + e = System.Console.ReadKey(True) if e.Key == System.ConsoleKey.PageDown: #PageDown self.scroll_window(12) elif e.Key == System.ConsoleKey.PageUp:#PageUp diff --git a/pyreadline/modes/basemode.py b/pyreadline/modes/basemode.py index 2ec43bf..1c82f69 100644 --- a/pyreadline/modes/basemode.py +++ b/pyreadline/modes/basemode.py @@ -407,7 +407,8 @@ class BaseMode(object): def ipython_paste(self,e): '''Paste windows clipboard. If enable_ipython_paste_list_of_lists is True then try to convert tabseparated data to repr of list of lists or - repr of array''' + repr of array. + If enable_ipython_paste_for_paths==True then change \\ to / and spaces to \space''' if self.enable_win32_clipboard: txt=clipboard.get_clipboard_text_and_convert( self.enable_ipython_paste_list_of_lists) diff --git a/pyreadline/release.py b/pyreadline/release.py index 0fab734..338af58 100644 --- a/pyreadline/release.py +++ b/pyreadline/release.py @@ -20,7 +20,7 @@ name = 'pyreadline' # because bdist_rpm does not accept dashes (an RPM) convention, and # bdist_deb does not accept underscores (a Debian convention). -branch = 'refactor' +branch = '' version = '1.4.3.rc1' @@ -35,11 +35,16 @@ it is based on the ctypes based UNC readline package by Gary Bishop. It is not complete. It has been tested for use with windows 2000 and windows xp. Features: - * Copy and paste using the clipboard - * Smart paste for convenient use with ipython. Converting tab separated data - to python list or numpy array. Converting file paths to use / and escaping - any spaces using \\\\ . - * Configuration file + * NEW: keyboard text selection and copy/paste + * Shift-arrowkeys for text selection + * Control-c can be used for copy activate with allow_ctrl_c(True) is config file + * Double tapping ctrl-c will raise a KeyboardInterrupt, use ctrl_c_tap_time_interval(x) + where x is your preferred tap time window, default 0.3 s. + * paste pastes first line of content on clipboard. + * ipython_paste, pastes tab-separated data as list of lists or numpy array if all data is numeric + * paste_mulitline_code pastes multi line code, removing any empty lines. + * Experimental support for ironpython. At this time Ironpython has to be patched for it to work. + The latest development version is always available at the IPython subversion repository_. @@ -54,7 +59,7 @@ authors = {'Jorgen' : ('Jorgen Stenarson','jorgen.stenarson@bostream.nu'), 'Jack': ('Jack Trainor', ''), } -url = 'http://projects.scipy.org/ipython/ipython/wiki/PyReadline/Intro' +url = 'http://ipython.scipy.org/moin/PyReadline/Intro' download_url = ''