mirror of
https://github.com/ArthurSonzogni/FTXUI.git
synced 2025-09-25 15:28:09 +08:00
Update document WIP.
This commit is contained in:

committed by
Arthur Sonzogni

parent
177df31d41
commit
75c424cea9
15
examples/dom/window.cpp
Normal file
15
examples/dom/window.cpp
Normal file
@@ -0,0 +1,15 @@
|
||||
// Copyright 2020 Arthur Sonzogni. All rights reserved.
|
||||
// Use of this source code is governed by the MIT license that can be found in
|
||||
// the LICENSE file.
|
||||
|
||||
#include <ftxui/dom/elements.hpp>
|
||||
#include <ftxui/screen/screen.hpp>
|
||||
#include <iostream>
|
||||
|
||||
int main(int argc, const char* argv[]) {
|
||||
using namespace ftxui;
|
||||
auto document = window(text(L"Title"), text(L"content"));
|
||||
auto screen = Screen::Create(Dimension::Fixed(30), Dimension::Fixed(6));
|
||||
Render(screen, document);
|
||||
std::cout << screen.ToString() << std::endl;
|
||||
}
|
Reference in New Issue
Block a user