summaryrefslogtreecommitdiff
path: root/Lib/idlelib/macosxSupport.py
diff options
context:
space:
mode:
authorNed Deily <nad@acm.org>2011-01-30 00:18:47 +0000
committerNed Deily <nad@acm.org>2011-01-30 00:18:47 +0000
commit2a6f4b33271742f66a8e58a5ffd37e890e0acae3 (patch)
treef700af54ef3679d888485306243ab6e3f0d115b2 /Lib/idlelib/macosxSupport.py
parentefc527a0cb65ec99e94712e715ed08782ade36be (diff)
downloadcpython-git-2a6f4b33271742f66a8e58a5ffd37e890e0acae3.tar.gz
Merged revisions 88003 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r88003 | ned.deily | 2011-01-14 20:37:12 -0800 (Fri, 14 Jan 2011) | 5 lines #10907: Warn OS X 10.6 IDLE users to use ActiveState Tcl/Tk 8.5, rather than the currently problematic Apple-supplied one, when running with the 64-/32-bit installer variant. ........
Diffstat (limited to 'Lib/idlelib/macosxSupport.py')
-rw-r--r--Lib/idlelib/macosxSupport.py17
1 files changed, 17 insertions, 0 deletions
diff --git a/Lib/idlelib/macosxSupport.py b/Lib/idlelib/macosxSupport.py
index 4438bd2a67..722ac54055 100644
--- a/Lib/idlelib/macosxSupport.py
+++ b/Lib/idlelib/macosxSupport.py
@@ -34,6 +34,23 @@ def isCarbonAquaTk(root):
'AppKit' not in root.tk.call('winfo', 'server', '.'))
return _carbonaquatk
+def tkVersionWarning(root):
+ """
+ Returns a string warning message if the Tk version in use appears to
+ be one known to cause problems with IDLE. The Apple Cocoa-based Tk 8.5
+ that was shipped with Mac OS X 10.6.
+ """
+
+ if (runningAsOSXApp() and
+ ('AppKit' in root.tk.call('winfo', 'server', '.')) and
+ (root.tk.call('info', 'patchlevel') == '8.5.7') ):
+ return (r"WARNING: The version of Tcl/Tk (8.5.7) in use may"
+ r" be unstable.\n"
+ r"Visit http://www.python.org/download/mac/tcltk/"
+ r" for current information.")
+ else:
+ return False
+
def addOpenEventSupport(root, flist):
"""
This ensures that the application will respont to open AppleEvents, which