--- a/demos/02_curses.py Fri Mar 28 10:44:29 2014 +0100
+++ b/demos/02_curses.py Fri Mar 28 14:58:12 2014 +0100
@@ -12,11 +12,11 @@
'lightmagenta', 'yellow', 'white')
buffer = Buffer(16, 8)
-buffer.fill(c='#')
-buffer.hline(1, 1, 14, c='-')
-buffer.hline(1, 6, 14, c='-')
-buffer.vline(7, 2, 4, c='|')
-buffer.puts(8, 4, 'Hello!')
+buffer.fill('#')
+buffer.hline('-', 1, 1, 14)
+buffer.hline('-', 1, 6, 14)
+buffer.vline('|', 7, 2, 4)
+buffer.puts('Hello!', 8, 4)
buffer.frame()
buffer2 = Buffer(30, 10)
@@ -25,7 +25,7 @@
for idx, color in enumerate(colors):
buffer2.setattr(color)
- buffer2.puts(3 + 12 * (idx // 8), 1 + idx % 8, color)
+ buffer2.puts(color, 3 + 12 * (idx // 8), 1 + idx % 8)
buffer3 = Buffer(30, 10)
buffer3.setattr('white on black')
@@ -33,12 +33,12 @@
for idx, color in enumerate(colors[:8]):
buffer3.setattr('black on {}'.format(color))
- buffer3.puts(2, 1 + idx, ' '+color.ljust(10))
+ buffer3.puts(' '+color.ljust(10), 2, 1 + idx)
buffer3.setattr('{}, underline, bold'.format(color))
- buffer3.puts(15, 1 + idx, ' '+color.ljust(10))
+ buffer3.puts(' '+color.ljust(10), 15, 1 + idx)
buffer3.setattr('lightgray, blink')
-buffer3.puts(3, 8, 'blink')
+buffer3.puts('blink', 3, 8)
driver = CursesDriver()
with driver: