Table of Contents

Class OutputBuffer

Namespace
Terminal.Gui
Assembly
Terminal.Gui.dll

Stores the desired output state for the whole application. This is updated during draw operations before being flushed to the console as part of MainLoop<T> operation

public class OutputBuffer : IOutputBuffer
Inheritance
OutputBuffer
Implements
Inherited Members

Properties

Clip

Gets or sets the clip rectangle that AddRune(Rune) and AddStr(string) are subject to.

Col

Gets the column last set by Move(int, int). Col and Row are used by AddRune(Rune) and AddStr(string) to determine where to add content.

Cols

The number of columns visible in the terminal.

Contents

The contents of the application output. The driver outputs this buffer to the terminal when UpdateScreen is called. The format of the array is rows, columns. The first index is the row, the second index is the column.

CurrentAttribute

The Attribute that will be used for the next AddRune(Rune) or AddStr(string) call.

DirtyLines

As performance is a concern, we keep track of the dirty lines and only refresh those. This is in addition to the dirty flag on each cell.

Left

The leftmost column in the terminal.

Row

Gets the row last set by Move(int, int). Col and Row are used by AddRune(Rune) and AddStr(string) to determine where to add content.

Rows

The number of rows visible in the terminal.

Top

The topmost row in the terminal.

Methods

AddRune(char)

Adds the specified char to the display at the current cursor position. This method is a convenience method that calls AddRune(Rune) with the Rune constructor.

AddRune(Rune)

Adds the specified rune to the display at the current cursor position.

AddStr(string)

Adds the str to the display at the cursor position.

ClearContents()

Clears the Contents of the driver.

FillRect(Rectangle, char)

Fills the given rect with the given symbol using the currently selected attribute.

FillRect(Rectangle, Rune)

Fills the given rect with the given symbol using the currently selected attribute.

IsValidLocation(Rune, int, int)

Tests whether the specified coordinate are valid for drawing the specified Rune.

Move(int, int)

Updates Col and Row to the specified column and row in Contents. Used by AddRune(Rune) and AddStr(string) to determine where to add content.

SetWindowSize(int, int)

Changes the size of the buffer to the given size