-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathmain.cpp
More file actions
29 lines (21 loc) · 707 Bytes
/
main.cpp
File metadata and controls
29 lines (21 loc) · 707 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#include "consui.h"
using namespace ConsUI;
void description(Canvas *cv)
{
cv->setBackground(Cyan);
cv->add(new Label(-100, 5, "TITLE", Magenta, White));
cv->endHeader();
cv->add(new TextField(-40, 3, "username", 'u', false, White, Blue));
cv->add(new TextField(-40, 3, "password", 'p', true, White, Blue));
cv->add(new Padding(-40, 3));
cv->beginHorizontal();
cv->add(new Button(-40, 3, "login", nullptr, 'l', Blue, White));
cv->add(new Button(-40, 3, "regist", nullptr, 'r', Green, White));
cv->endHorizontal();
cv->beginTailer();
cv->add(new Label(-100, 5, "TAILER", Red, White));
}
int main()
{
Screen::initRoot(new Canvas(description));
}