--- a/tuikit/driver.py Tue Oct 11 10:09:58 2011 +0200
+++ b/tuikit/driver.py Wed Oct 12 00:58:46 2011 +0200
@@ -16,9 +16,11 @@
'''Clipping region stack.'''
self.unigraph = UnicodeGraphics()
'''Unicode graphics characters.'''
+ self.colorprefix = []
+ '''Stack of color prefixes.'''
- # drawing
+ ## drawing ##
def puts(self, x, y, s):
'''Output string of characters.'''
@@ -55,4 +57,12 @@
self.vline(x, y+1, h-2, self.unigraph.VLINE)
self.vline(x+w-1, y+1, h-2, self.unigraph.VLINE)
-
\ No newline at end of file
+
+ ## colors ##
+
+ def pushcolorprefix(self, name):
+ self.colorprefix.append(name)
+
+ def popcolorprefix(self):
+ self.colorprefix.pop()
+