Reprint please specify the source:
Http://www.cnblogs.com/darkknightzh/p/6066697.html
Reference URL:
Http://www.tuicool.com/articles/jIbAjy
Http://stackoverflow.com/questions/1718403/enable-bash-output-color-with-lua-script
C + + in
"""\033[0m";
Note: It does not seem to revert to the default color, the following will always be the color set.
which
#define RESET "\033[0m" #define Black "\033[30m"/ * Black */#define RED "\033[31m"/ * Red */# Define green "\033[32m"/ * Green */#define YELLOW "\033[33m"/ * YELLOW */#define BLUE "\033[34m" c10/>/* Blue/#define MAGENTA "\033[35m"/ * MAGENTA */#define CYAN "\033[36m"/ * CYAN */#define White< c14/> "\033[37m"/* White/ #define Boldblack "\033[1m\033[30m"/ * Bold Black */#define boldred "\ 033[1m\033[31m "/ * Bold Red */#define Boldgreen " \033[1m\033[32m "/ * Bold Green */#define Boldyellow "\033[1m\033[33m"/ * Bold Yellow */#define Boldblue "\033[1m\033[34m"/ * Bold Blue */#define Boldmagenta "\033[1m\033[35m"/ * Bold Magenta */#define Boldcyan "\033[1m\033[36m"/ * Bold Cyan */# Define Boldwhite "\033[1m\033[37m"/ * Bold White */
Torch Medium:
Print (String.Format("\27[31m str:%s", Strval))
Note: 1. Where \27 is the decimal 27, corresponding to the 8 binary 033.
2. Appears to be valid only for the current row. The next line or the default color.
(original + turn) Ubuntu terminal output Color text