Imported Upstream version 1.22.4
[platform/upstream/groff.git] / contrib / hdtbl / examples / color_boxes.roff
1 .ig
2 color_boxes.roff
3
4 This file is part of groff, the GNU roff type-setting system.
5
6 Copyright (C) 2005-2018 Free Software Foundation, Inc.
7 written by Joachim Walsdorff <Joachim.Walsdorff@urz.uni-heidelberg.de>.
8
9 groff is free software; you can redistribute it and/or modify it under
10 the terms of the GNU General Public License as published by the Free
11 Software Foundation, either version 3 of the License, or
12 (at your option) any later version.
13
14 groff is distributed in the hope that it will be useful, but WITHOUT
15 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
16 FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
17 for more details.
18
19 You should have received a copy of the GNU General Public License
20 along with this program.  If not, see <http://www.gnu.org/licenses/>.
21 ..
22 .
23 .if !d sopath \
24 .  ds sopath
25 .
26 .so \*[sopath]examples/common.roff
27 .
28 .\" Seed the random number generator for reproducible builds.
29 .random-seed 131545532 19201711
30 .
31 .H Horizontal Rules and Boxes .br with Randomly Colored Border and Background
32 .PN 25 Text before horizontal rule.
33 .TBL border=.5n bc=green bgc=red width=7c tal=c csp=.2n cpd=.3n .TR .TD .ETB
34 .PN 10 Text after horizontal rule and before table.
35 .de ctab
36 .nr ? 0 1
37 .PN 5 .random# ".defcolor color\En+? rgb \E*[#random]" 
38 .TD ".TBL border=1c bc=color1 csp=0 cpd=0 height=3c bgc=color2" .TR .TD .ETB
39 ..
40 .
41 .TBL tal=c border= csp=0 cpd=0 cols=5 width=3c
42 .PN 2 .TR ".PN 5 .ctab"
43 .ETB 
44 .PN 15 Text after table.
45 .TBL border=.5n bc=color1 bgc=color2 width=15c tal=c csp=.2n cpd=.3n .TR .TD .ETB
46 .PN 25 Text after horizontal rule.
47 .
48 .\" ====================================================================
49 .\" Editor settings
50 .\" ====================================================================
51 .
52 .\" Local Variables:
53 .\" mode: nroff
54 .\" fill-column: 72
55 .\" End:
56 .\" vim: set filetype=groff textwidth=72: