FTXUI 6.1.9
C++ functional terminal UI.
Chargement...
Recherche...
Aucune correspondance
separator_style.cpp
Aller à la documentation de ce fichier.
1// Copyright 2020 Arthur Sonzogni. Tous droits réservés.
2// L'utilisation de ce code source est régie par la licence MIT qui se trouve dans
3// le fichier LICENSE.
4#include <ftxui/screen/screen.hpp> // for Screen
5#include <iostream> // for endl, cout, ostream
6#include <memory> // for allocator
7
8#include "ftxui/dom/elements.hpp" // for text, hbox, separatorDouble, separatorHeavy, separatorLight, vbox, operator|, Element, Fit, borderDouble, borderHeavy, borderLight
9#include "ftxui/dom/node.hpp" // for Render
10#include "ftxui/screen/box.hpp" // for ftxui
11
12int main() {
13 using namespace ftxui;
14
15 auto document = vbox({
16 vbox({
17 text("separatorLight"),
18 separatorLight(),
19 hbox(text("left"), separatorLight(), text("right")),
20 }) | borderLight,
21
22 vbox({
23 text("separatorDashed"),
24 separatorDashed(),
25 hbox(text("left"), separatorDashed(), text("right")),
26 }) | borderDashed,
27
28 vbox({
29 text("separatorHeavy"),
30 separatorHeavy(),
31 hbox(text("left"), separatorHeavy(), text("right")),
32 }) | borderHeavy,
33
34 vbox({
35 text("separatorDouble"),
36 separatorDouble(),
37 hbox(text("left"), separatorDouble(), text("right")),
38 }) | borderDouble,
39 });
40
41 auto screen =
42 Screen::Create(Dimension::Fit(document), Dimension::Fit(document));
43 Render(screen, document);
44 screen.Print();
45 std::cout << std::endl;
46}
auto screen
void Render(Screen &screen, const Element &element)
Affiche un élément sur un ftxui::Screen.
Definition node.cpp:83
L'espace de noms FTXUI ftxui::
Definition animation.hpp:10
int main()