argos_colored_text.h File Reference
#include <argos3/core/utility/datatypes/datatypes.h>
Include dependency graph for argos_colored_text.h:

Go to the source code of this file.

Classes

struct  argos::SLogColor
 Stream modifier to set attribute and color of the subsequent text. More...
 

Namespaces

 argos
 The namespace containing all the ARGoS related code.
 

Macros

#define DEFINE_ARGOS_STREAM_COLOR_HELPER(lc_color, uc_color)
 Utility macro to ease the definition of the presets. More...
 

Enumerations

enum  argos::EARGoSLogAttributes {
  argos::ARGOS_LOG_ATTRIBUTE_RESET = 0 , argos::ARGOS_LOG_ATTRIBUTE_BRIGHT = 1 , argos::ARGOS_LOG_ATTRIBUTE_DIM = 2 , argos::ARGOS_LOG_ATTRIBUTE_UNDERSCORE = 3 ,
  argos::ARGOS_LOG_ATTRIBUTE_BLINK = 5 , argos::ARGOS_LOG_ATTRIBUTE_REVERSE = 7 , argos::ARGOS_LOG_ATTRIBUTE_HIDDEN = 8
}
 The possible attributes of the logged text. More...
 
enum  argos::EARGoSLogColors {
  argos::ARGOS_LOG_COLOR_BLACK = 0 , argos::ARGOS_LOG_COLOR_RED = 1 , argos::ARGOS_LOG_COLOR_GREEN = 2 , argos::ARGOS_LOG_COLOR_YELLOW = 3 ,
  argos::ARGOS_LOG_COLOR_BLUE = 4 , argos::ARGOS_LOG_COLOR_MAGENTA = 5 , argos::ARGOS_LOG_COLOR_CYAN = 6 , argos::ARGOS_LOG_COLOR_WHITE = 7
}
 The possible colors of the logged text. More...
 

Functions

std::ostream & argos::operator<< (std::ostream &c_os, const SLogColor &s_log_color)
 Stream operator that accepts the stream modifier. More...
 
 argos::DEFINE_ARGOS_STREAM_COLOR_HELPER (red, RED)
 Bright red text modifier. More...
 
 argos::DEFINE_ARGOS_STREAM_COLOR_HELPER (green, GREEN)
 Bright green text modifier. More...
 
 argos::DEFINE_ARGOS_STREAM_COLOR_HELPER (yellow, YELLOW)
 Bright yellow text modifier. More...
 
 argos::DEFINE_ARGOS_STREAM_COLOR_HELPER (blue, BLUE)
 Bright blue text modifier. More...
 
 argos::DEFINE_ARGOS_STREAM_COLOR_HELPER (magenta, MAGENTA)
 Bright magenta text modifier. More...
 
 argos::DEFINE_ARGOS_STREAM_COLOR_HELPER (cyan, CYAN)
 Bright cyan text modifier. More...
 
 argos::DEFINE_ARGOS_STREAM_COLOR_HELPER (white, WHITE)
 Bright white text modifier. More...
 
std::ostream & argos::reset (std::ostream &c_os)
 Resets the text to the default settings. More...
 

Macro Definition Documentation

◆ DEFINE_ARGOS_STREAM_COLOR_HELPER

#define DEFINE_ARGOS_STREAM_COLOR_HELPER (   lc_color,
  uc_color 
)
Value:
inline std::ostream& lc_color(std::ostream& c_os) { \
c_os << SLogColor(ARGOS_LOG_ATTRIBUTE_BRIGHT, ARGOS_LOG_COLOR_ ## uc_color); \
return c_os; \
}
@ ARGOS_LOG_ATTRIBUTE_BRIGHT

Utility macro to ease the definition of the presets.

Definition at line 89 of file argos_colored_text.h.