FTXUI
6.1.9
C++ functional terminal UI.
Chargement...
Recherche...
Aucune correspondance
vbox_hbox.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 que l'on peut trouver dans
3
// le fichier LICENSE.
4
#include <stdio.h>
// for getchar
5
#include <
ftxui/dom/elements.hpp
>
// for filler, text, hbox, vbox
6
#include <
ftxui/screen/screen.hpp
>
// for Full, Screen
7
#include <memory>
// for allocator
8
9
#include "
ftxui/dom/node.hpp
"
// for Render
10
#include "
ftxui/screen/color.hpp
"
// for ftxui
11
12
int
main
() {
13
using namespace
ftxui
;
14
auto
document =
//
15
vbox({
16
hbox({
17
text(
"north-west"
),
18
filler(),
19
text(
"north-east"
),
20
}),
21
filler(),
22
hbox({
23
filler(),
24
text(
"center"
),
25
filler(),
26
}),
27
filler(),
28
hbox({
29
text(
"south-west"
),
30
filler(),
31
text(
"south-east"
),
32
}),
33
});
34
auto
screen
= Screen::Create(Dimension::Full());
35
Render
(
screen
, document);
36
screen
.Print();
37
getchar();
38
39
return
0;
40
}
color.hpp
screen
auto screen
Definition
composition.cpp:56
elements.hpp
Render
void Render(Screen &screen, const Element &element)
Affiche un élément sur un ftxui::Screen.
Definition
node.cpp:83
ftxui
L'espace de noms FTXUI ftxui::
Definition
animation.hpp:10
node.hpp
screen.hpp
main
int main()
Definition
vbox_hbox.cpp:12