Emit a new line when a component is interrupted.

While running a component, make sure to reset the cursor at the end of
the component and insert a new line.

This fixes:
https://github.com/ArthurSonzogni/FTXUI/issues/6
This commit is contained in:
ArthurSonzogni 2019-09-18 22:02:51 +02:00
parent e1efcf2d97
commit 7f0381e30a

View File

@ -111,7 +111,7 @@ void ScreenInteractive::Loop(Component* component) {
std::cout << reset_cursor_position;
std::cout << SHOW_CURSOR;
std::cout << ENABLE_LINE_WRAP;
std::cout << std::flush;
std::cout << std::endl;
});
// Handle resize.