API Reference
VtOutput
The interactive VT output. Print-once blocks are appended to scrollback; live frames are drawn on the alternate screen, diffed against the previous frame and written in one synchronized update (DEC mode 2026), so the screen never shows a half-drawn frame. The bottom-right cell is never written, which avoids an unwanted scroll on any terminal.
Inheritance
- Object
- VtOutput
Constructors
public VtOutput(ITerminalWriter writer, TerminalProfile profile, Boolean ownsWriter = true) #Creates a VT output.
Parameters
- writer ConsoleMonster.Output.ITerminalWriter
- The sink.
- profile ConsoleMonster.Capabilities.TerminalProfile
- The profile (colour depth, size).
- ownsWriter System.Boolean = true
- Whether disposing this output disposes the writer.
Methods
public Void BeginLive() #VoidStarts live rendering (VT: alternate screen, hidden cursor). No effect for line-based outputs.
public Void Dispose() #VoidPerforms application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
public Void EndLive() #VoidEnds live rendering and restores the terminal (cursor, screen, attributes). Safe to call more than once.
public Void Invalidate() #VoidForces the next frame to be redrawn completely (after a resize or external output).
public Void RenderFrame(CellBuffer frame) #VoidDraws a full-screen frame, writing only the cells that changed since the previous frame.
Parameters
- frame ConsoleMonster.Canvas.CellBuffer
- The frame; its size is the screen size.
public Void WriteBlock(CellBuffer buffer) #VoidAppends a rendered block (print-once output) to the scrollback.
Parameters
- buffer ConsoleMonster.Canvas.CellBuffer
- The rendered block; trailing blank cells on each row are trimmed.
public Void WriteInline(StyledLine line) #VoidWrites one styled line without ending it (Write-ConsoleText -NoNewLine); the next write continues on it.
Parameters
- line ConsoleMonster.Text.StyledLine
- The line.
public Void WriteInPlace(StyledLine line, Boolean final) #VoidRedraws one line in place (an updating status line): carriage return, the line, clear to the end of the line. With final the line ends and later output starts below it.
Parameters
- line ConsoleMonster.Text.StyledLine
- The line; keep it narrower than the window so it never wraps.
- final System.Boolean
- Whether this is the last version of the line.
public Void WriteLine(StyledLine line) #VoidAppends one styled line (stream narration, captured output, summaries).
Parameters
- line ConsoleMonster.Text.StyledLine
- The line.
Inherited Methods
public virtual Boolean Equals(Object? obj) #BooleanParameters
- obj Object?