Compositors

Term.Compositors.CompositorType
mutable struct Compositor
    layout::Expr
    elements::Dict{Symbol,LayoutElement}
end

A layout compositor, creates an updatable layout from an expression.

source
Term.Compositors.CompositorMethod
Compositor(layout::Expr; hpad::Int = 0, vpad::Int = 0, check::Bool = true, kwargs...)

Constructor. Parses a layout expression and creates LayoutElements for each element in the expression.

source
Base.showMethod

Base.show(io::IO, ::MIME"text/plain", compositor::Compositor)

Show a compositor.

source
Term.Compositors.renderMethod
render(compositor::Compositor; show_placeholders = false)

Render a compositor's current layout.

Get a renderable from each LayoutElement in the compositor and evaluate the layout expression interpolating the renderables.

source
Term.update!Method
function update!(
    compositor::Compositor,
    id::Symbol,
    content::Union{String,AbstractRenderable},
)

Update a LayoutElement in a Compositor with new content. If the content's measure doesn't match the pre-defined size of the LayoutElement, it prints a warning message.

source