Format: \033[display mode; foreground color; background colour m
Description
Foreground background color
---------------------------------------
30 40 Black
31 41 Red
32 42 Green
33 43 Yellow
34 44 Blue
35 45 Purplish red
36 46 Cyan Blue
37 47 White
Meaning of display mode
-------------------------
0 Terminal default settings
1 highlighting
4 using underscores
5 Flashing
7 Anti-white display
8 Not visible
Example:
\033[1;31;40m <!--1-highlight 31-foreground color Red 40-background black--
\033[0m <!--Use the terminal default setting, which cancels the color setting--
print ' \033[1;31;40m '
print ' * ' * 50
print ' *host:\t ', request. Meta.get (' REMOTE_ADDR ')
print ' *uri:\t ', Request.path
print ' *args:\t ', querydict (request.body)
print ' *time:\t ', Time.time ()-Request.start_time
print ' * ' * 50
print ' \033[0m '
[Python][odlboy] Sets the color of the string to print