From 55d035113dfb1bd90495c8571758f504ae8d4802 Mon Sep 17 00:00:00 2001
From: Terry Jan Reedy The Shell window also has an output squeezing facility explained in the
-the Python Shell window subsection below. The Shell window also has an output squeezing facility explained in the Python
+Shell window subsection below.
A Tk Text widget, and hence IDLE’s Shell, displays characters (codepoints) -in the the BMP (Basic Multilingual Plane) subset of Unicode. -Which characters are displayed with a proper glyph and which with a -replacement box depends on the operating system and installed fonts. -Tab characters cause the following text to begin after -the next tab stop. (They occur every 8 ‘characters’). -Newline characters cause following text to appear on a new line. -Other control characters are ignored or displayed as a space, box, or -something else, depending on the operating system and font. -(Moving the text cursor through such output with arrow keys may exhibit -some surprising spacing behavior.)
->>> s = 'a\tb\a<\x02><\r>\bc\nd'
->>> len(s)
-14
->>> s # Display repr(s)
-'a\tb\x07<\x02><\r>\x08c\nd'
->>> print(s, end='') # Display s as is.
-# Result varies by OS and font. Try it.
+A Tk Text widget, and hence IDLE’s Shell, displays characters (codepoints) in
+the BMP (Basic Multilingual Plane) subset of Unicode. Which characters are
+displayed with a proper glyph and which with a replacement box depends on the
+operating system and installed fonts. Tab characters cause the following text
+to begin after the next tab stop. (They occur every 8 ‘characters’). Newline
+characters cause following text to appear on a new line. Other control
+characters are ignored or displayed as a space, box, or something else,
+depending on the operating system and font. (Moving the text cursor through
+such output with arrow keys may exhibit some surprising spacing behavior.)
+>>> s = 'a\tb\a<\x02><\r>\bc\nd' # Enter 22 chars.
+>>> len(s)
+14
+>>> s # Display repr(s)
+'a\tb\x07<\x02><\r>\x08c\nd'
+>>> print(s, end='') # Display s as is.
+# Result varies by OS and font. Try it.
The repr
function is used for interactive echo of expression
@@ -912,7 +910,7 @@ also used for testing.