ftxui::InputOption
cpp
#include <ftxui/component/component_options.hpp>Option for the Input component.
Examples: component/homescreen, component/input
Summary
| Symbol | Description |
|---|---|
on_change | Called when the content changes. |
on_enter | Called when the user presses enter. |
password | Obscure the input content using '*'. |
cursor_position | When set different from -1, this attributes is used to store the cursor position. |
Public Attributes
on_change
cpp
std::function< void()> on_change = [] {};Called when the content changes.
on_enter
cpp
std::function< void()> on_enter = [] {};Called when the user presses enter.
password
cpp
Ref< bool > password = false;Obscure the input content using '*'.
Examples: component/input
cursor_position
cpp
Ref< int > cursor_position = -1;When set different from -1, this attributes is used to store the cursor position.