|
CIOF v1.0.0-build
Char Input Output Format - A simple Input and Output utility library
|
Namespaces | |
| namespace | impl |
| Implementation functions. | |
Classes | |
| struct | CIOFOutputConfig |
| Set output configuration for ciof::impl::__out() function and its wrappers. More... | |
Typedefs | |
| typedef struct ciof::CIOFOutputConfig | CIOFOutputConfig |
| Set output configuration for ciof::impl::__out() function and its wrappers. | |
Enumerations | |
| enum class | OutputStyle { Bold , Italic , Underline , Strikethrough } |
| Set output style: Bold Italic Underline Strikethrough. More... | |
| enum class | OutputType { Out , Err , Log } |
| Set output type for ciof::impl::__out() function and its helper functions Out : To Standard Output Err : To Standard Error Log : To Standard Log (Error, unbuffered) More... | |
Functions | |
| std::string | colorSet (int _color) |
| Set the colors from the default color palette from the terminal. | |
| void | cursorPos (int _row, int _col) |
| Get the set cursor position using _row and _col Essentially calls the getCursorPos() function and then sets the row and col according to the getCursorPos() function. | |
| template<typename T> | |
| void | echo (T _t) |
| Echo to the standard output for _t | |
| template<typename T, typename ... Args> | |
| void | echo (T _t, Args ... _args) |
| Echo to the standard output for _t | |
| template<typename T> | |
| void | echoError (T _t) |
| Echo to the standard error for _t | |
| template<typename T, typename ... Args> | |
| void | echoError (T _t, Args ... _args) |
| Echo to the standard log for _t | |
| template<typename T> | |
| void | echoLog (T _t) |
| Echo to the standard log for _t | |
| template<typename T, typename ... Args> | |
| void | echoLog (T _t, Args ... _args) |
| Echo to the standard log for _t | |
| template<typename T, typename ... Args> | |
| std::string | format (T _t, Args ... _args) |
| Get everything as a string format. | |
| std::string | getCursorPos (int _row, int _col) |
| Get the set cursor position using _row and _col. | |
| void | initANSI () |
| Initialize ANSI text option in Windows 10 or later NOTE: ONLY WORKS IN WINDOWS 10 OR LATER. | |
| template<typename T> | |
| void | input (const std::string &_prompt, T *_var) |
| Get full input from the user with a prompt. | |
| template<typename T> | |
| void | input (T *_var) |
| Get full input from the user. | |
| void | print () |
| Print a new line. | |
| template<typename T> | |
| void | print (T _t) |
| Print to the standard output for _t | |
| template<typename T, typename ... Args> | |
| void | print (T _t, Args ... _args) |
| Print to the standard output for _t | |
| template<typename T> | |
| void | printError (T _t) |
| Print to the standard error for _t | |
| template<typename T, typename ... Args> | |
| void | printError (T _t, Args ... _args) |
| Print to the standard error for _t | |
| template<typename T> | |
| void | printLog (T _t) |
| Print to the standard log for _t | |
| template<typename T, typename ... Args> | |
| void | printLog (T _t, Args ... _args) |
| Print to the standard log for _t | |
| std::string | rgbSet (unsigned int r, unsigned int g, unsigned int b) |
| Set the RGB color in the terminal. | |
| std::string | styleReset () |
| Reset all the styles and colors in the terminal. | |
| std::string | styleSet (const OutputStyle &_style) |
| Set the styles according to the OutputStyle type. | |
Variables | |
| CIOFOutputConfig | outputConf |
| Set default output configuration. | |
| typedef struct ciof::CIOFOutputConfig ciof::CIOFOutputConfig |
Set output configuration for ciof::impl::__out() function and its wrappers.
|
strong |
|
strong |
Set output type for ciof::impl::__out() function and its helper functions Out : To Standard Output Err : To Standard Error Log : To Standard Log (Error, unbuffered)
| Enumerator | |
|---|---|
| Out | |
| Err | |
| Log | |
Definition at line 37 of file ciof.hpp.
| std::string ciof::colorSet | ( | int | _color | ) |
| void ciof::cursorPos | ( | int | _row, |
| int | _col ) |
Get the set cursor position using _row and _col Essentially calls the getCursorPos() function and then sets the row and col according to the getCursorPos() function.
| _row | Row to set (X) |
| _col | Column to set (Y) |
Definition at line 23 of file ciof.cpp.
References getCursorPos().
| void ciof::echo | ( | T | _t | ) |
Echo to the standard output for _t
| _t | Message to print |
| void ciof::echo | ( | T | _t, |
| Args ... | _args ) |
Echo to the standard output for _t
| _t | Message to print |
| _args | More messages to add |
| void ciof::echoError | ( | T | _t | ) |
Echo to the standard error for _t
| _t | Message to print |
| void ciof::echoError | ( | T | _t, |
| Args ... | _args ) |
Echo to the standard log for _t
| _t | Message to print |
| _args | More messages to add |
| void ciof::echoLog | ( | T | _t | ) |
Echo to the standard log for _t
| _t | Message to print |
| void ciof::echoLog | ( | T | _t, |
| Args ... | _args ) |
Echo to the standard log for _t
| _t | Message to print |
| _args | More messages to add |
| std::string ciof::format | ( | T | _t, |
| Args ... | _args ) |
Get everything as a string format.
| _t | First param of the string |
| _args | Rest of the params of the string |
| std::string ciof::getCursorPos | ( | int | _row, |
| int | _col ) |
Get the set cursor position using _row and _col.
| _row | Row to set (X) |
| _col | Column to set (Y) |
Definition at line 20 of file ciof.cpp.
Referenced by cursorPos().
| void ciof::initANSI | ( | ) |
Initialize ANSI text option in Windows 10 or later NOTE: ONLY WORKS IN WINDOWS 10 OR LATER.
Definition at line 26 of file ciof.cpp.
| void ciof::input | ( | const std::string & | _prompt, |
| T * | _var ) |
Get full input from the user with a prompt.
| _prompt | Prompt to user |
| _var | Variable to store the value |
| void ciof::input | ( | T * | _var | ) |
Get full input from the user.
| _prompt | Prompt to user |
| _var | Variable to store the value |
| void ciof::print | ( | ) |
| void ciof::print | ( | T | _t | ) |
Print to the standard output for _t
| _t | Message to print |
| void ciof::print | ( | T | _t, |
| Args ... | _args ) |
Print to the standard output for _t
| _t | Message to print |
| _args | More messages to add |
| void ciof::printError | ( | T | _t | ) |
Print to the standard error for _t
| _t | Message to print |
| void ciof::printError | ( | T | _t, |
| Args ... | _args ) |
Print to the standard error for _t
| _t | Message to print |
| _args | More messages to add |
| void ciof::printLog | ( | T | _t | ) |
Print to the standard log for _t
| _t | Message to print |
| void ciof::printLog | ( | T | _t, |
| Args ... | _args ) |
Print to the standard log for _t
| _t | Message to print |
| _args | More messages to add |
| std::string ciof::rgbSet | ( | unsigned int | r, |
| unsigned int | g, | ||
| unsigned int | b ) |
| std::string ciof::styleReset | ( | ) |
| std::string ciof::styleSet | ( | const OutputStyle & | _style | ) |
Set the styles according to the OutputStyle type.
| _style | Set the style (Bold, Italics, Underline, ...) |
Definition at line 44 of file ciof.cpp.
References Bold, Italic, Strikethrough, and Underline.
| CIOFOutputConfig ciof::outputConf |