cmdr
Check-in [8358279e61]
Not logged in
Bounty program for improvements to Tcl and certain Tcl packages.
Tcl 2018 Conference, Houston/TX, US, Oct 15-19
Send your abstracts to tclconference@googlegroups.com
or submit via the online form by Aug 20.

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:cmdr::color - Added standard symbolic color "heading", for use by cmdr::table.
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:8358279e615c4d87b796e3bdc6fee73032a7636b
User & Date: aku 2016-06-29 07:04:46
Context
2016-06-29
07:09
cmdr::color - Add forgotten docs about new symbolic name. check-in: d1c012590f user: aku tags: trunk
07:04
cmdr::color - Added standard symbolic color "heading", for use by cmdr::table. check-in: 8358279e61 user: aku tags: trunk
07:03
cmdr::table - Documented the package. Added testsuite. Added more validation and introspection. Added TEApot metadata. check-in: 7acf8ff192 user: aku tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to tests/color.test.

8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
..
33
34
35
36
37
38
39

40
41
42
43
44
45
46
..
85
86
87
88
89
90
91

92
93
94
95
96
97
98
kt require support Tclx
kt require support debug
kt require support debug::caller

kt local   support cmdr::tty
kt local   testing cmdr::color

set thecolors {advisory bad bg-black bg-blue bg-cyan bg-default bg-green bg-magenta bg-red bg-white bg-yellow black blink blue bold confirm cyan default dim error good green hidden italic magenta name neutral no no-blink no-bold no-dim no-hidden no-italic no-revers no-strike no-underline note number prompt red reset revers strike underline unknown warning white yellow yes}

set thechars {
    advisory	{\033[33m}
    bad		{\033[31m}
    bg-black	{\033[40m}
    bg-blue	{\033[44m}
    bg-cyan	{\033[46m}
................................................................................
    confirm	{\033[31m}
    cyan	{\033[36m}
    default	{\033[39m}
    dim		{\033[2m}
    error	{\033[35m}
    good	{\033[32m}
    green	{\033[32m}

    hidden	{\033[8m}
    italic	{\033[3m}
    magenta	{\033[35m}
    name	{\033[34m}
    neutral	{\033[34m}
    no		{\033[31m}
    no-blink	{\033[25m}
................................................................................
    confirm	=red
    cyan	e36
    default	e39
    dim		e2
    error	=magenta
    good	=green
    green	e32

    hidden	e8
    italic	e3
    magenta	e35
    name	=blue
    neutral	=blue
    no		=red
    no-blink	e25







|







 







>







 







>







8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
..
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
..
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
kt require support Tclx
kt require support debug
kt require support debug::caller

kt local   support cmdr::tty
kt local   testing cmdr::color

set thecolors {advisory bad bg-black bg-blue bg-cyan bg-default bg-green bg-magenta bg-red bg-white bg-yellow black blink blue bold confirm cyan default dim error good green heading hidden italic magenta name neutral no no-blink no-bold no-dim no-hidden no-italic no-revers no-strike no-underline note number prompt red reset revers strike underline unknown warning white yellow yes}

set thechars {
    advisory	{\033[33m}
    bad		{\033[31m}
    bg-black	{\033[40m}
    bg-blue	{\033[44m}
    bg-cyan	{\033[46m}
................................................................................
    confirm	{\033[31m}
    cyan	{\033[36m}
    default	{\033[39m}
    dim		{\033[2m}
    error	{\033[35m}
    good	{\033[32m}
    green	{\033[32m}
    heading	{\033[1m}
    hidden	{\033[8m}
    italic	{\033[3m}
    magenta	{\033[35m}
    name	{\033[34m}
    neutral	{\033[34m}
    no		{\033[31m}
    no-blink	{\033[25m}
................................................................................
    confirm	=red
    cyan	e36
    default	e39
    dim		e2
    error	=magenta
    good	=green
    green	e32
    heading	=bold
    hidden	e8
    italic	e3
    magenta	e35
    name	=blue
    neutral	=blue
    no		=red
    no-blink	e25

Changes to utilities/color.tcl.

345
346
347
348
349
350
351



352
353
354
355
356
357
358
    define  no       =red
    define  note     =blue
    define  number   =green
    define  prompt   =blue
    define  unknown  =cyan
    define  warning  =yellow
    define  yes      =green




    variable smap {}
}

apply {{} {
    variable smap
    for {set i 0} {$i < 32} {incr i} {







>
>
>







345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
    define  no       =red
    define  note     =blue
    define  number   =green
    define  prompt   =blue
    define  unknown  =cyan
    define  warning  =yellow
    define  yes      =green

    # Standard for cmdr::table
    define  heading  =bold

    variable smap {}
}

apply {{} {
    variable smap
    for {set i 0} {$i < 32} {incr i} {