summaryrefslogtreecommitdiffstats
path: root/Mac/Demo/waste
diff options
context:
space:
mode:
authorJack Jansen <jack.jansen@cwi.nl>2001-08-03 13:31:36 (GMT)
committerJack Jansen <jack.jansen@cwi.nl>2001-08-03 13:31:36 (GMT)
commitcbed91b4db6817b7bbbb12ede40bfb5d26a9bf14 (patch)
tree1995f01bd8828ae9647ad407e40dd8584ca843da /Mac/Demo/waste
parentcb60dae6a1a7841138421866ea15870f6297cf8b (diff)
downloadcpython-cbed91b4db6817b7bbbb12ede40bfb5d26a9bf14.zip
cpython-cbed91b4db6817b7bbbb12ede40bfb5d26a9bf14.tar.gz
cpython-cbed91b4db6817b7bbbb12ede40bfb5d26a9bf14.tar.bz2
Merging appropriate 2.1.1 fixes back into the main trunk.
Diffstat (limited to 'Mac/Demo/waste')
-rw-r--r--Mac/Demo/waste/htmled.py7
-rw-r--r--Mac/Demo/waste/swed.py4
-rw-r--r--Mac/Demo/waste/wed.py4
3 files changed, 10 insertions, 5 deletions
diff --git a/Mac/Demo/waste/htmled.py b/Mac/Demo/waste/htmled.py
index 7643947..4d29e1e 100644
--- a/Mac/Demo/waste/htmled.py
+++ b/Mac/Demo/waste/htmled.py
@@ -15,7 +15,6 @@ import Scrap
import os
import macfs
import MACFS
-import regsub
import string
import htmllib
@@ -47,7 +46,7 @@ class WasteWindow(ScrolledWindow):
self.path = path
self.name = name
r = windowbounds(400, 400)
- w = Win.NewWindow(r, name, 1, 0, -1, 1, 0x55555555)
+ w = Win.NewWindow(r, name, 1, 0, -1, 1, 0)
self.wid = w
vr = LEFTMARGIN, 0, r[2]-r[0]-15, r[3]-r[1]-15
dr = (0, 0, vr[2], 0)
@@ -445,7 +444,7 @@ class WasteWindow(ScrolledWindow):
self.ted.WEInsert(data, None, None)
def send_literal_data(self, data):
- data = regsub.gsub('\n', '\r', data)
+ data = string.replace(data, '\n', '\r')
data = string.expandtabs(data)
self.ted.WEInsert(data, None, None)
@@ -775,6 +774,8 @@ class Wed(Application):
def idle(self, event):
if self.active:
self.active.do_idle(event)
+ else:
+ Qd.SetCursor(Qd.qd.arrow)
def newRuler(self, obj):
"""Insert a new ruler. Make it as wide as the window minus 2 pxls"""
diff --git a/Mac/Demo/waste/swed.py b/Mac/Demo/waste/swed.py
index b62fd9a..e4622da 100644
--- a/Mac/Demo/waste/swed.py
+++ b/Mac/Demo/waste/swed.py
@@ -34,7 +34,7 @@ class WasteWindow(ScrolledWindow):
self.path = path
self.name = name
r = windowbounds(400, 400)
- w = Win.NewWindow(r, name, 1, 0, -1, 1, 0x55555555)
+ w = Win.NewWindow(r, name, 1, 0, -1, 1, 0)
self.wid = w
vr = 0, 0, r[2]-r[0]-15, r[3]-r[1]-15
dr = (0, 0, 10240, 0)
@@ -603,6 +603,8 @@ class Wed(Application):
def idle(self, event):
if self.active:
self.active.do_idle(event)
+ else:
+ Qd.SetCursor(Qd.qd.arrow)
def getfontnames():
names = []
diff --git a/Mac/Demo/waste/wed.py b/Mac/Demo/waste/wed.py
index 7b40864..342d52e 100644
--- a/Mac/Demo/waste/wed.py
+++ b/Mac/Demo/waste/wed.py
@@ -25,7 +25,7 @@ class WasteWindow(ScrolledWindow):
self.path = path
self.name = name
r = windowbounds(400, 400)
- w = Win.NewWindow(r, name, 1, 0, -1, 1, 0x55555555)
+ w = Win.NewWindow(r, name, 1, 0, -1, 1, 0)
self.wid = w
vr = 0, 0, r[2]-r[0]-15, r[3]-r[1]-15
dr = (0, 0, 10240, 0)
@@ -411,6 +411,8 @@ class Wed(Application):
def idle(self, event):
if self.active:
self.active.do_idle(event)
+ else:
+ Qd.SetCursor(Qd.qd.arrow)
def main():
App = Wed()