width and height were being set using the incorrect axes resulting in incorrect canvas dimensions
Co-authored-by: ArthurSonzogni <sonzogniarthur@gmail.com>
- Fix focus in flexbox. This required resetting the focus state at the
beginning of the ComputeRequirement(), because it can now run several
times.
This resolves:https://github.com/ArthurSonzogni/FTXUI/issues/399
- Add Box::Union.
- Add a preliminary implementation of forwarding selected_box from
within the flexbox.
The table is not meant to be used to render more than once. Reset the
dimensions so that, even if it is used wrongly, this is not memory
unsafe.
This was raised by:
https://github.com/ArthurSonzogni/FTXUI/issues/381
Add decorator variants for decorator components
Add the "pipe" operator for components, similar to what was done for Elements.
We are able to put something like:
```
Button(...) | Maybe(&show_button)
```
Add decorators for:
- `Maybe`
- `CatchEvent`
- `Renderer`
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
Co-authored-by: ArthurSonzogni <sonzogniarthur@gmail.com>
before this change, the example in the doxygen document for CatchEvent()
does not use the documented function. hence the example is not that
useful for developers interested in a typical usage of this function.
after this change, the example is improved to added the call to
CatchEvent(), which allows the application to the Loop() function at
user input.
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
- Provide better defaults for ComponentBase `Focusable()` and
`ActiveChild()` methods. This resolves:
https://github.com/ArthurSonzogni/FTXUI/issues/335
- Implement `Container::Tab` 's `Focusable()` methods. This prevents
the users to navigate into a tab with no interactivity.
PREFIX is by default "lib", which most of the libraries use.
this changes makes the library files libftxui-foo.a
as ArthurSonzogni/FTXUI#140 intended originally
ftxui::Ref<> is used for passing Options, for instance, MenuOption,
to the corresponding component which is supposed to hold a strong
reference of it. and we can observe the events sent to the component
by setting callback(s) in the option instance passed to the owner
component.
but the callback function is not always copyable, despite that it
might be moveable.
in this change,
* Make<>() is updated to use the perfect forwarding to avoid
enforcing its parameters to be copyable.
* Ref<> is also updated to take a rvalue reference, so we can
move away from the contructor parameter when creating an
instance of Ref<>() from it.
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
- Add support for SIGTSTP:
https://github.com/ArthurSonzogni/FTXUI/issues/330
This
- Add support for task posting.
This allows folks to defer function execution, and execute it directly
below the main loop. The task are executed in a FIFO order.