Ned Deily added the comment:

It's helpful to keep in mind that IDLE is a Tk application written in Python 
and, as such, depends on Tk to do nearly everything associated with writing to 
displays and reading from keyboards and pointing devices.  If you try 
outputting the same string using the Tk shell, wish, you'll see exactly the 
same behavior as you do in IDLE:

$ wish
% .text insert 1.0 "hello\b\b\b\b\bHELLO"
% pack .text

And you'll see the same Tk platform differences.  With the native OS X Tk's, 
the backspace characters aren't displayed; with a Linux or OS X X11 Tk, empty 
box characters are displayed.  That may also depend on which font is in use.  
In any case, the Tk text widget does not behave the same way in this regard as 
most terminal emulator windows do would do with backspace characters.  So it's 
up to any Tk app to figure out how it wants to deal with them.

This issue has come up before for Tkinter in general: back in 2001, effbot 
suggested some code to search for and edit backspace runs in Tk text.  
Presumably something similar could be added to IDLE if there was general 
agreement that this was desirable (after verifying that it works on all of the 
Tk platforms that IDLE supports).  See 
https://mail.python.org/pipermail/python-list/2001-December/085908.html

----------
nosy: +ned.deily

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue23220>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to