summaryrefslogtreecommitdiffstats
path: root/Demo/tkinter/matt
diff options
context:
space:
mode:
Diffstat (limited to 'Demo/tkinter/matt')
-rw-r--r--Demo/tkinter/matt/bind-w-mult-calls-p-type.py1
-rw-r--r--Demo/tkinter/matt/entry-with-shared-variable.py3
-rw-r--r--Demo/tkinter/matt/pong-demo-1.py2
-rw-r--r--Demo/tkinter/matt/printing-coords-of-items.py2
4 files changed, 2 insertions, 6 deletions
diff --git a/Demo/tkinter/matt/bind-w-mult-calls-p-type.py b/Demo/tkinter/matt/bind-w-mult-calls-p-type.py
index af0ec81..0da7c37 100644
--- a/Demo/tkinter/matt/bind-w-mult-calls-p-type.py
+++ b/Demo/tkinter/matt/bind-w-mult-calls-p-type.py
@@ -1,5 +1,4 @@
from tkinter import *
-import string
# This program shows how to use a simple type-in box
diff --git a/Demo/tkinter/matt/entry-with-shared-variable.py b/Demo/tkinter/matt/entry-with-shared-variable.py
index 473a596..7d93da7 100644
--- a/Demo/tkinter/matt/entry-with-shared-variable.py
+++ b/Demo/tkinter/matt/entry-with-shared-variable.py
@@ -1,5 +1,4 @@
from tkinter import *
-import string
# This program shows how to make a typein box shadow a program variable.
@@ -35,7 +34,7 @@ class App(Frame):
# because it's being looked at by the entry widget, changing
# the variable changes the entry widget display automatically.
# the strange get/set operators are clunky, true...
- str = string.upper(self.contents.get())
+ str = self.contents.get().upper()
self.contents.set(str)
def print_contents(self, event):
diff --git a/Demo/tkinter/matt/pong-demo-1.py b/Demo/tkinter/matt/pong-demo-1.py
index 09f9f2e..82a5dc0 100644
--- a/Demo/tkinter/matt/pong-demo-1.py
+++ b/Demo/tkinter/matt/pong-demo-1.py
@@ -1,7 +1,5 @@
from tkinter import *
-import string
-
class Pong(Frame):
def createWidgets(self):
diff --git a/Demo/tkinter/matt/printing-coords-of-items.py b/Demo/tkinter/matt/printing-coords-of-items.py
index 26a4649..771a60d 100644
--- a/Demo/tkinter/matt/printing-coords-of-items.py
+++ b/Demo/tkinter/matt/printing-coords-of-items.py
@@ -35,7 +35,7 @@ class Test(Frame):
# the "current" tag is applied to the object the cursor is over.
# this happens automatically.
self.draw.itemconfig(CURRENT, fill="red")
- print(self.draw.coords(CURRENT))
+ print(list(self.draw.coords(CURRENT)))
def mouseLeave(self, event):
# the "current" tag is applied to the object the cursor is over.