summaryrefslogtreecommitdiffstats
path: root/Lib/idlelib/calltip_w.py
diff options
context:
space:
mode:
authorTerry Jan Reedy <tjreedy@udel.edu>2018-06-20 03:00:35 (GMT)
committerGitHub <noreply@github.com>2018-06-20 03:00:35 (GMT)
commit06e2029dfa500a42e3565ed7ba8573412f153d1c (patch)
treef9fe4e4683e94c09ef7d807295c3f8c26b00b437 /Lib/idlelib/calltip_w.py
parent4d92158f4c3917fc4fbfebff15224e74782abf79 (diff)
downloadcpython-06e2029dfa500a42e3565ed7ba8573412f153d1c.zip
cpython-06e2029dfa500a42e3565ed7ba8573412f153d1c.tar.gz
cpython-06e2029dfa500a42e3565ed7ba8573412f153d1c.tar.bz2
bpo-33907: Rename an IDLE module and class. (GH-7807)
Improve consistency and appearance. Module idlelib.calltips is now calltip. Class idlelib.calltip_w.CallTip is now Calltip.
Diffstat (limited to 'Lib/idlelib/calltip_w.py')
-rw-r--r--Lib/idlelib/calltip_w.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/Lib/idlelib/calltip_w.py b/Lib/idlelib/calltip_w.py
index 122b73a..b75e4c2 100644
--- a/Lib/idlelib/calltip_w.py
+++ b/Lib/idlelib/calltip_w.py
@@ -1,7 +1,7 @@
-"""A CallTip window class for Tkinter/IDLE.
+"""A Calltip window class for Tkinter/IDLE.
After tooltip.py, which uses ideas gleaned from PySol
-Used by the calltips IDLE extension.
+Used by calltip.
"""
from tkinter import Toplevel, Label, LEFT, SOLID, TclError
@@ -13,7 +13,7 @@ CHECKHIDE_TIME = 100 # milliseconds
MARK_RIGHT = "calltipwindowregion_right"
-class CallTip:
+class Calltip:
def __init__(self, widget):
self.widget = widget
@@ -47,7 +47,7 @@ class CallTip:
def showtip(self, text, parenleft, parenright):
"""Show the calltip, bind events which will close it and reposition it.
"""
- # Only called in CallTips, where lines are truncated
+ # Only called in Calltip, where lines are truncated
self.text = text
if self.tipwindow or not self.text:
return
@@ -147,7 +147,7 @@ def _calltip_window(parent): # htest #
text.pack(side=LEFT, fill=BOTH, expand=1)
text.insert("insert", "string.split")
top.update()
- calltip = CallTip(text)
+ calltip = Calltip(text)
def calltip_show(event):
calltip.showtip("(s=Hello world)", "insert", "end")
@@ -161,7 +161,7 @@ def _calltip_window(parent): # htest #
if __name__ == '__main__':
from unittest import main
- main('idlelib.idle_test.test_calltips', verbosity=2, exit=False)
+ main('idlelib.idle_test.test_calltip_w', verbosity=2, exit=False)
from idlelib.idle_test.htest import run
run(_calltip_window)