diff options
author | Terry Jan Reedy <tjreedy@udel.edu> | 2014-01-23 00:39:11 -0500 |
---|---|---|
committer | Terry Jan Reedy <tjreedy@udel.edu> | 2014-01-23 00:39:11 -0500 |
commit | 8860443749295acbeecb074be8460113fc478468 (patch) | |
tree | ad145c69d866167c57f4ced8eb15bf53a102f854 /Lib/idlelib/EditorWindow.py | |
parent | 42d9e1b9f3ac02169336016d203b7ff78eb72882 (diff) | |
parent | 94338de49b6eb67efbaae6112787f2596a16d9d6 (diff) | |
download | cpython-git-8860443749295acbeecb074be8460113fc478468.tar.gz |
Merge with 3.3
Diffstat (limited to 'Lib/idlelib/EditorWindow.py')
-rw-r--r-- | Lib/idlelib/EditorWindow.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/Lib/idlelib/EditorWindow.py b/Lib/idlelib/EditorWindow.py index f855bc6de3..390ffab9b7 100644 --- a/Lib/idlelib/EditorWindow.py +++ b/Lib/idlelib/EditorWindow.py @@ -1,6 +1,7 @@ import importlib import importlib.abc import os +from platform import python_version import re import string import sys @@ -955,11 +956,14 @@ class EditorWindow(object): self.undo.reset_undo() def short_title(self): + pyversion = "Python " + python_version() + ": " filename = self.io.filename if filename: filename = os.path.basename(filename) + else: + filename = "Untitled" # return unicode string to display non-ASCII chars correctly - return self._filename_to_unicode(filename) + return pyversion + self._filename_to_unicode(filename) def long_title(self): # return unicode string to display non-ASCII chars correctly |