RootNode

termflow.tui.RootNode
final case class RootNode(width: Int, height: Int, children: List[VNode], input: Option[InputNode], overlays: List[Overlay], layout: Option[Layout])

The top-level virtual-DOM container produced by TuiApp.view.

RootNode declares the logical frame size and a list of children plus an optional focused input. The actual terminal width/height is read from the backend by the renderer; the width/height here are the app's own idea of the drawing surface and are used by AnsiRenderer.buildFrame to size the cell matrix.

Value parameters

children

Static nodes to draw, in document order.

height

Frame height in cells.

input

Optional focused InputNode rendered last, with cursor placement.

layout

Optional Layout resolved by the renderer at render time using the frame's (width, height) as the size budget. Distinct from children (positioned-node authoring): apps using layout get reflow-on-resize and Layout.Fill semantics for free. Both children and layout may be present — children paints first, then the resolved layout.

overlays

Optional stack of Overlays composited on top of the base view, in document order (bottom-to-top z-order). When any overlay sets inputCapture = InputCapture.Modal, the base view's input is suppressed and the topmost modal overlay's input (if any) takes over the hardware cursor.

width

Frame width in cells.

Attributes

Graph
Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all

Members list

Value members

Inherited methods

def productElementNames: Iterator[String]

Attributes

Inherited from:
Product
def productIterator: Iterator[Any]

Attributes

Inherited from:
Product