class

TermBuf::BufferSurface

Inherits TermBuf::Drawing < Reference < Object

Stability: stable — changes only in a major release.

A drawing surface that writes into a buffer as commands arrive.

The core layer's answer to Terminal: everything built on Drawing works against it, with no device, no fibres, and nothing to tear down afterwards.

Constructors

new(buffer : Buffer)

A drawing surface over buffer. Commands are applied as they arrive, on whichever fibre issued them.

Source

Class methods

apply(command : Command, buffer : Buffer) : Bool

Applies the commands that need nothing but a buffer, and reports whether command was one of them.

A class method because the owning fibre needs the same lines and has its own reasons to keep hold of the ones this leaves alone.

Source

Instance methods

buffer

What is being drawn on.

Source
issue(command : Command) : Nil

Applies command, ignoring the ones that need a terminal to mean anything.

Source
policy

What the buffer being drawn into measures with.

Source