demos/01_buffer.py
author Radek Brich <radek.brich@devl.cz>
Mon, 16 Feb 2015 21:17:43 +0100
changeset 117 8680c2333546
parent 95 05392e369ede
permissions -rwxr-xr-x
Update FixedLayout. Add demo launcher.

#!/usr/bin/env python3

from tuikit.core.buffer import Buffer
from tuikit.driver.driver import Driver


buffer = Buffer(16, 8)
buffer.fill('#')
buffer.hline('-', 1, 1, 14)
buffer.hline('-', 1, 6, 14)
buffer.vline('|', 7, 2, 4)
buffer.puts('Hello!', 8, 4)
buffer.frame()

driver = Driver()
driver.init()
driver.draw(buffer)
driver.close()