New submission from Tal Einat:

Patch adding a 'Paste Code' item to the 'Edit' menu, as well as hotkeys.

Using 'Paste Code' instead of the normal paste will remove prompts ('>>>
' or '... ') from the code, and also remove empty lines if pasting to a
shell window.

This allows easily copy/pasting code between shell and editor windows,
as well as easily pasting code from other applications (e.g. a web
browser) into IDLE.

This patch uses IDLE's PyParse.py for parsing code, and Tk's clipboard
API for interaction with the clipboard (it changes the clipboard's
contents, generates a normal paste event, and changes the contents back).

Test only on WinXP SP2 so far, needs to be tested on other platforms,
especially the clipboard interaction.

----------
components: IDLE
files: IDLE_paste_code.070918.patch
messages: 56017
nosy: taleinat
severity: minor
status: open
title: IDLE - add "paste code" functionality
type: behavior
versions: Python 2.6

__________________________________
Tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue1178>
__________________________________

Attachment: IDLE_paste_code.070918.patch
Description: Binary data

_______________________________________________
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to