Skip to content

Modern Tui TuiBuffer

Paul Squires edited this page Oct 19, 2026 · 6 revisions

Home › Terminal TUI Library › Buffer and Frame › TuiBuffer

TuiBuffer

Holds a grid of character cells, stored row by row.

Syntax

type TuiBuffer
    as TuiCellArray cells
    as int32 cols, rows
    ...
end type

Description

A flat grid of cells, row-major. TuiScreen owns two of these -- front and back -- and the diff is the comparison between them.

Example

#import "std/tui"
using tui

dim as TuiBuffer b
b.Resize( 20, 5 )
print b.cols, b.rows, b.Count( )       '' 20 5 100

b.Clear( TuiStyleDefault( ) )
print b.At( 0, 0 )->width              '' 1 -- a blank

See also

TuiCell TuiCell.Equals TuiBuffer.Resize TuiBuffer.InBounds TuiBuffer.Count TuiFrame.Area
TuiCell.SetChar TuiCellBlank TuiBuffer.Clear TuiBuffer.At TuiFrame TuiFrame.Clip

Library: Terminal TUI Library
Category: Terminal TUI Library
Documented under: Buffer and Frame
Working examples: hello.tiko · form.tiko · dashboard.tiko


Home · Keyword Index

Clone this wiki locally