Color-Table in C Programming Language
Following colors are available for use in c graphics programming.
Color Table :
Total number of colors available depend on current graphics driver and mode. Use colors name in capital letters, for example use setcolor(RED) not setcolor(red) the latter will give you an error. You may use number instead of color for example setbkcolor(GREEN) or setbkcolor(2) are same, but you are advised to use color name as it will improve readability of program.
Following colors are available for use in c graphics programming.
Color Table :
COLOR | VALUE |
BLACK | 0 |
BLUE | 1 |
GREEN | 2 |
CYAN | 3 |
RED | 4 |
MAGENTA | 5 |
BROWN | 6 |
LIGHTBLUE | 7 |
DARKGRAY | 8 |
LIGHTBLUE | 9 |
LIGHTGREEN | 10 |
LIGHTCYAN | 11 |
LIGHTRED | 12 |
LIGHTMAGENTA | 13 |
YELLOW | 14 |
WHITE | 15 |
Total number of colors available depend on current graphics driver and mode. Use colors name in capital letters, for example use setcolor(RED) not setcolor(red) the latter will give you an error. You may use number instead of color for example setbkcolor(GREEN) or setbkcolor(2) are same, but you are advised to use color name as it will improve readability of program.
0 comments: