Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/tawindow.py
diff options
context:
space:
mode:
authorWalter Bender <walter@walter-laptop.(none)>2010-02-06 02:47:48 (GMT)
committer Walter Bender <walter@walter-laptop.(none)>2010-02-06 02:47:48 (GMT)
commit6a3eecfae933b26f447c1bdc05d46c57cc9d9523 (patch)
tree8104f1560d56d06f423b5007371db7cb8b9f016b /tawindow.py
parentd9c4ce39be3990b2dcb6219908b44abd00c40e5e (diff)
unhighlight on run
Diffstat (limited to 'tawindow.py')
-rw-r--r--tawindow.py47
1 files changed, 47 insertions, 0 deletions
diff --git a/tawindow.py b/tawindow.py
index 9c57355..ca378e2 100644
--- a/tawindow.py
+++ b/tawindow.py
@@ -1884,3 +1884,50 @@ class TurtleArtWindow():
return False
else:
return True
+
+ def showlabel(self, label, str=''):
+ if label=='#nostack':
+ shp = 'nostack'
+ label=''
+ elif label=='#noinput':
+ shp = 'noinput'
+ label=''
+ elif label=='#emptyheap':
+ shp = 'emptyheap'
+ label=''
+ elif label=='#emptybox':
+ shp = 'emptybox'
+ label=''
+ elif label=='#nomedia':
+ shp = 'nomedia'
+ label=''
+ elif label=='#nocode':
+ shp = 'nocode'
+ label=''
+ elif label=='#syntaxerror':
+ shp = 'syntaxerror'
+ label=''
+ elif label=='#overflowerror':
+ shp = 'overflowerror'
+ label=''
+ elif label=='#notanumber':
+ shp = 'overflowerror'
+ label=''
+ elif label=='#trace':
+ shp = 'info'
+ label = str
+ else:
+ shp = 'status'
+ self.status_spr.set_shape(self.status_shapes[shp])
+ self.status_spr.set_label(label)
+ self.status_spr.set_layer(STATUS_LAYER)
+
+ def calc_position(self, t):
+ w,h,x,y,dx,dy = TEMPLATES[t]
+ x *= self.canvas.width
+ y *= self.canvas.height
+ w *= (self.canvas.width-x)
+ h *= (self.canvas.height-y)
+ dx *= w
+ dy *= h
+ return(w,h,x,y,dx,dy)