color

It's the ANSI standard, was used a lot in the old BBS days.


\\033 = [Esc] (up in your keyboard top left corner)

Colors:
\\033[30m set foreground color to black

\\033[31m set foreground color to red

\\033[32m set foreground color to green

\\033[33m set foreground color to yellow

\\033[34m set foreground color to blue

\\033[35m set foreground color to magenta (purple)

\\033[36m set foreground color to cyan

\\033[37m set foreground color to white

\\033[40m set background color to black

\\033[41m set background color to red

\\033[42m set background color to green

\\033[43m set background color to yellow

\\033[44m set background color to blue

\\033[45m set background color to magenta (purple)

\\033[46m set background color to cyan

\\033[47m set background color to white

\\033[1;30m set foreground color to dark gray

\\033[1;31m set foreground color to light red

\\033[1;32m set foreground color to light green

\\033[1;33m set foreground color to yellow

\\033[1;34m set foreground color to light blue

\\033[1;35m set foreground color to light magenta (purple)

\\033[1;36m set foreground color to light cyan

\\033[1;37m set foreground color to white

\\033[1;40m set background color to dark gray

\\033[1;41m set background color to light red

\\033[1;42m set background color to light green

\\033[1;43m set background color to yellow

\\033[1;44m set background color to light blue

\\033[1;45m set background color to light magenta (purple)

\\033[1;46m set background color to light cyan

\\033[1;47m set background color to white

For other features:
\\033[0m reset; clears all colors and styles (to white on black)

\\033[1m bold on

\\033[3m italics on

\\033[4m underline on

\\033[5m blink on

\\033[7m reverse video on

\\033[8m nondisplayed (invisible)

\\033[x;yH moves cursor to line x, column y

\\033[xA moves cursor up x lines

\\033[xB moves cursor down x lines

\\033[xC moves cursor right x spaces

\\033[xD moves cursor left x spaces

\\033[2J clear screen and home cursor
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值