Use std::string by default for the implementation of FTXUI's input
component.
Along the way:
- Give a correct implementation for fullwidth characters.
- Add tests
- Modify the way the cursor is drawn.
This implement the flexbox elements, following the HTML one.
Built from them, there is also the following elements:
- `paragraph`
- `paragraphAlignLeft`
- `paragraphAlignRight`
- `paragraphAlignCenter`
- `paragraphAlignJustify`
This is a breaking change.
In case of embedded systems, the terminal size may not
always be detectable (e.g. in case of serial output).
Allow application to set up the default size in case
autodetection fails. On platform such as Emscripten,
there is only "fallback" size.
Signed-off-by: Jarosław Pelczar <jarek@jpelczar.com>
Msvc defined its own (lowercase) macros for min/max. Because of this, the std::min and std::max functions need to be explicitly included or otherwise are not availible.
In the msvc 2019 compiler this issue seems fixed. However, on msvc 2017 not including <algorithm> causes compilation errors. Adding the include is a simple fix that does not hurt the other platforms and enables compilation on msvc 2017.
- Let the global `BUILD_SHARED_LIBS` dictates whether the library should
be built statically or dynamically. The cmake's default is statically.
- Add library version and symlink.
This lead to the following install tree.
.
├── include
│ └── ftxui
│ ├── component [...]
│ ├── dom [...]
│ ├── screen [...]
│ └── util [...]
└── lib
├── cmake
│ └── ftxui
│ ├── ftxui-config.cmake
│ ├── ftxui-config-version.cmake
│ └── ftxui-config-version-noconfig.cmake
├── ftxui-component.so -> ftxui-component.so.0.10.369
├── ftxui-component.so.0.10.369
├── ftxui-dom.so -> ftxui-dom.so.0.10.369
├── ftxui-dom.so.0.10.369
├── ftxui-screen.so -> ftxui-screen.so.0.10.369
└── ftxui-screen.so.0.10.369
Fixed: https://github.com/ArthurSonzogni/FTXUI/issues/223
This can happen for example in embedded linux, in case
the application is started via serial terminal.
Signed-off-by: Jarosław Pelczar <jarek@jpelczar.com>
Co-authored-by: ArthurSonzogni <sonzogniarthur@gmail.com>
Dom
- `vscroll_indicator`. Show a scrollback indicator on the right.
Component
- `Maybe`: Display an component conditionnally based on a boolean.
- `Dropdown`: A dropdown select list.
This address:
https://github.com/ArthurSonzogni/FTXUI/issues/204
- Password is now taking a ref, allowing a shared state to be used by
multiple passwords.
- Password cursor position is now optional. It will be used only when
set to something different from -1.
Screen::ApplyShader accounted for 60% of the computation. This patch
optimize it.
Performance on a 80x80 frame improved from 1400 draw/s to 7000 draw/s.