You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
25 lines
485 B
25 lines
485 B
2 months ago
|
#include <ftxui/dom/elements.hpp>
|
||
|
#include <ftxui/screen/screen.hpp>
|
||
|
#include <iostream>
|
||
|
|
||
|
int main(void) {
|
||
|
using namespace ftxui;
|
||
|
|
||
|
// Define the document
|
||
|
Element document =
|
||
|
hbox({
|
||
|
text("left") | border,
|
||
|
text("middle") | border | flex,
|
||
|
text("right") | border,
|
||
|
});
|
||
|
|
||
|
auto screen = Screen::Create(
|
||
|
Dimension::Full(), // Width
|
||
|
Dimension::Fit(document) // Height
|
||
|
);
|
||
|
Render(screen, document);
|
||
|
screen.Print();
|
||
|
|
||
|
return EXIT_SUCCESS;
|
||
|
}
|