Board logo

标题: [其他] cecho - 单行显示多种颜色 [打印本页]

作者: tmplinshi    时间: 2012-10-30 10:08     标题: cecho - 单行显示多种颜色

Color Echo by Jason Hood <[email]jadoxa@yahoo.com.au[/email]>.
Version 0.90 (12 July, 2004). Public Domain.
http://misc.adoxa.cjb.net/

Display text using any color you like.

Usage: cecho text
       cecho --map[b|B|x]
       cecho --<attr>

"text" is output as-is, with the exception of '#' sequences:

fb      foreground color and optional background color:
            n  black      N  dark gray          :  current color
            r  red        R  bright red
            g  green      G  bright green
            b  blue       B  bright blue
            c  cyan       C  bright cyan
            m  magenta    M  bright magenta
            y  brown      Y  yellow
            w  gray       W  white

~       restore original color
=       keep current color on exit
;       don't end with new line

#       #               ,       tab
a       &               _       new line
o       |               d       ding
s       <               h       backspace
l       >               [       escape

xhh     character represented by one- or two-digit hexadecimal number
ddc     repeat 'c' (which may be a '#' sequence) dd times, which may be
        a one- or two-digit decimal number

-       stop '#' processing
+       start '#' processing (only if stopped)
.       really stop '#' processing (quote remaining text)

Any character following '#' not present in the above list will be output
untranslated (along with the '#').

--map will display all the foreground colors with normal background colors;
b will use the bright background colors; and B will display both (assumes 80
columns). --mapx will display the extended ASCII characters.

--<attr> will set the color to <attr>, a decimal number between 0 and 255.
The current attribute is returned when displaying "text".


示例1 - 显示所有颜色:
cecho --map



示例2:
cecho #GbTest....#GyTest....#_#RnTest



-----------------------------------
官网: http://adoxa.3eeweb.com/misc/index.html
-----------------------------------

http://bcn.bathome.net/s/tool/index.html?key=cecho
作者: yu2n    时间: 2012-11-4 15:57

这个简单易用
作者: wpNature    时间: 2013-1-10 23:25

正好需要这个工具,非常感谢。
作者: zhaoker    时间: 2013-1-14 17:26

爽死我了!




欢迎光临 批处理之家 (http://bbs.bathome.net/) Powered by Discuz! 7.2