23 auto RendererInfo = [](
const std::string& name,
int*
size) {
25 return text(name +
": " + std::to_string(*size)) |
center;
29 auto left = RendererInfo(
"Left", &left_size);
30 auto right = RendererInfo(
"Right", &right_size);
31 auto top = RendererInfo(
"Top", &top_size);
32 auto bottom = RendererInfo(
"Bottom", &bottom_size);
34 auto container = middle;
43 screen.Loop(renderer);
static ScreenInteractive Fullscreen()
Component ResizableSplitTop(Component main, Component back, int *main_size)
An vertical split in between two components, configurable using the mouse.
Component Renderer(Component child, std::function< Element()>)
Return a new Component, similar to |child|, but using |render| as the Component::Render() event.
Component ResizableSplitRight(Component main, Component back, int *main_size)
An horizontal split in between two components, configurable using the mouse.
Component ResizableSplitBottom(Component main, Component back, int *main_size)
An vertical split in between two components, configurable using the mouse.
Component ResizableSplitLeft(Component main, Component back, int *main_size)
An horizontal split in between two components, configurable using the mouse.
Decorator size(WidthOrHeight, Constraint, int value)
Apply a constraint on the size of an element.
Element center(Element)
Center an element horizontally and vertically.
Element text(std::wstring text)
Display a piece of unicode text.
Element border(Element)
Draw a border around the element.
The FTXUI ftxui:: namespace.