Terminal++ 3.1.0.4
A C++ library for interacting with ANSI terminal windows
|
A class that encapsulates a terminal. More...
#include <terminal.hpp>
Public Types | |
using | read_function = std::function< void(terminalpp::tokens)> |
using | write_function = std::function< void(terminalpp::bytes)> |
Public Member Functions | |
template<typename Channel > | |
terminal (Channel &channel, behaviour beh=behaviour{}) | |
Constructor. | |
terminal (terminal const &)=delete | |
Copy Constructor. | |
~terminal () | |
Destructor. | |
terminal & | operator= (terminal const &)=delete |
Copy Assignment. | |
void | async_read (std::function< void(tokens)> const &callback) |
Request that data be read from the terminal. | |
void | write (bytes data) |
Write data to the terminal. | |
bool | is_alive () const |
Returns whether the terminal is alive or not. | |
void | close () |
Closes the terminal. | |
void | set_size (extent size) |
Sets the size of the terminal. This is used to determine cursor locations when writing text that wraps at the end of the line, etc. | |
terminal & | operator<< (terminal_manipulator auto &&manip) |
Write to the terminal. | |
terminal & | operator<< (terminalpp::element const &elem) |
Write a single element to the terminal. | |
terminal & | operator<< (terminalpp::string const &text) |
Write an attributed string to the terminal. | |
A class that encapsulates a terminal.
A class that is used to stream data in and out of a terminal.
Write to the terminal.