92 bool Focusable()
const override {
return true; }
94 if (
event.is_mouse() && box_.Contain(
event.mouse().x,
event.mouse().y)) {
95 if (!CaptureMouse(
event)) {
It implement rendering itself as ftxui::Element. It implement keyboard navigation by responding to ft...
std::shared_ptr< Node > Element
std::shared_ptr< T > Make(Args &&... args)
std::function< Element(Element)> ElementDecorator
std::shared_ptr< ComponentBase > Component
Component Renderer(Component child, std::function< Element()>)
Return a new Component, similar to |child|, but using |render| as the Component::Render() event.
Decorator reflect(Box &box)
void Render(Screen &screen, const Element &element)
Display an element on a ftxui::Screen.
std::function< Component(Component)> ComponentDecorator
Represent an event. It can be key press event, a terminal resize, or more ...