FTXUI 6.1.9 C++ functional terminal UI.

Loading...
Searching...
No Matches
terminal.hpp
Go to the documentation of this file.
1// Copyright 2020 Arthur Sonzogni. All rights reserved.
2// Use of this source code is governed by the MIT license that can be found in
3// the LICENSE file.
4#ifndef FTXUI_SCREEN_TERMINAL_HPP
5#define FTXUI_SCREEN_TERMINAL_HPP
6
7 namespace ftxui {
8
9/// @brief Dimensions is a structure that represents the size of the terminal
10/// @ingroup screen
11 struct Dimensions {
12 int dimx;
13 int dimy;
14};
15
16 namespace Terminal {
17 Dimensions Size();
18 void SetFallbackSize(const Dimensions& fallbackSize);
19
20/// @brief Color is an enumeration that represents the color support of the
21/// terminal.
22/// @ingroup screen
23 enum Color {
24 Palette1,
25 Palette16,
26 Palette256,
27 TrueColor,
28};
29 Color ColorSupport();
30 void SetColorSupport(Color color);
31
32} // namespace Terminal
33
34} // namespace ftxui
35
36#endif // FTXUI_SCREEN_TERMINAL_HPP
ftxui::Terminal::SetColorSupport
void SetColorSupport(Color color)
Override terminal color support in case auto-detection fails.
Definition terminal.cpp:140
ftxui::Dimensions::dimy
int dimy
Definition terminal.hpp:13
ftxui::Dimensions::dimx
int dimx
Definition terminal.hpp:12
ftxui::Color
Color is a class that represents a color in the terminal user interface.
Definition color.hpp:22
ftxui::Terminal::Color
Color
Color is an enumeration that represents the color support of the terminal.
Definition terminal.hpp:23
ftxui::Terminal::Size
Dimensions Size()
Get the terminal size.
Definition terminal.cpp:94
ftxui::Terminal::ColorSupport
Color ColorSupport()
Get the color support of the terminal.
Definition terminal.cpp:130
ftxui::Terminal::TrueColor
@ TrueColor
Definition terminal.hpp:27
ftxui::Terminal::Palette256
@ Palette256
Definition terminal.hpp:26
ftxui::Terminal::Palette16
@ Palette16
Definition terminal.hpp:25
ftxui::Terminal::Palette1
@ Palette1
Definition terminal.hpp:24
ftxui::Dimensions
Dimensions is a structure that represents the size of the terminal.
Definition terminal.hpp:11
ftxui::Terminal::SetFallbackSize
void SetFallbackSize(const Dimensions &fallbackSize)
Override terminal size in case auto-detection fails.
Definition terminal.cpp:124
ftxui
The FTXUI ftxui:: namespace.
Definition animation.hpp:10