5 This file is part of groff, the GNU roff type-setting system.
7 Copyright (C) 2005-2018 Free Software Foundation, Inc.
8 written by Joachim Walsdorff <Joachim.Walsdorff@urz.uni-heidelberg.de>.
10 groff is free software; you can redistribute it and/or modify it under
11 the terms of the GNU General Public License as published by the Free
12 Software Foundation, either version 3 of the License, or
13 (at your option) any later version.
15 groff is distributed in the hope that it will be useful, but WITHOUT
16 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
17 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
20 You should have received a copy of the GNU General Public License
21 along with this program. If not, see <http://www.gnu.org/licenses/>.
28 .so \*[sopath]examples/common.roff
36 ".nr #cc +(1f / \\$1)" \
37 ".defcolor \En[t*#] rgb \\$2 \\$3 \\$4" \
38 ".TBL csp=\n[t*l]/(12*\\$1+2) border= cpd=0 bgc=\\\\n[t*#] bc=" \
39 ".if (\\\\n+[*#] == 1) \
40 .CPTN Rainbow Colors \[em] Nested Tables with Colored Backgrounds \
46 .ctab \n[*n] 1 0 \En[#cc]u \" rot -> magenta
47 .ctab \n[*n] 1-\En[#cc]u 0 1 \" magenta -> blue
48 .ctab \n[*n] 0 \En[#cc]u 1 \" blue -> cyan
49 .ctab \n[*n] 0 1 1-\En[#cc]u \" cyan -> green
50 .ctab \n[*n] \En[#cc]u 1 0 \" green -> yellow
51 .ctab \n[*n] 1 1-\En[#cc]u 0 \" yellow -> red
63 ".nr #cc +(1f / \\$1)" \
64 ".defcolor \En[t*#] rgb \\$2 \\$3 \\$4" \
65 ".TBL border=\n[t*l]/(12*\\$1+2) csp=0 cpd=0 bc=\\\\n[t*#] bgc=" \
66 ".if (\\\\n+[*#] == 1) \
67 .CPTN Rainbow Colors \[em] Nested Tables with Colored Borders \
73 .ctab \n[*n] 1 \En[#cc]u 0 \" red -> yellow
74 .ctab \n[*n] 1-\En[#cc]u 1 0 \" yellow -> green
75 .ctab \n[*n] 0 1 \En[#cc]u \" green -> cyan
76 .ctab \n[*n] 0 1-\En[#cc]u 1 \" cyan -> blue
77 .ctab \n[*n] \En[#cc]u 0 1 \" blue -> magenta
78 .ctab \n[*n] 1 0 1-\En[#cc]u \" magenta -> red
82 .\" ====================================================================
84 .\" ====================================================================
90 .\" vim: set filetype=groff textwidth=72: