Overview
Comment:Uses supertabular for long tables.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | origin/master | trunk
Files: files | file ages | folders
SHA3-256: cabb19c27f97d2da70e1108aa6af75b65cb141046ffee6bbda91c2fce5f9882a
User & Date: gawthrop@users.sourceforge.net on 1997-04-15 11:17:58.000
Other Links: branch diff | manifest | tags
Context
1997-04-15
11:18:49
Uses supertabular package check-in: 259ff48827 user: gawthrop@users.sourceforge.net tags: origin/master, trunk
11:17:58
Uses supertabular for long tables. check-in: cabb19c27f user: gawthrop@users.sourceforge.net tags: origin/master, trunk
09:49:04
Initial revision check-in: 0f5da0b8c1 user: gawthrop@users.sourceforge.net tags: origin/master, trunk
Changes
11
12
13
14
15
16
17



18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33









34
35
36


37
38




39
40
41
42
43
44
45
46
47

48
49

50
51
52
53
54
55

56
57
58
59
60
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33



34
35
36
37
38
39
40
41
42
43
44
45
46
47


48
49
50
51
52
53
54
55
56
57
58
59

60
61

62
63
64
65
66
67

68
69
70
71
72
73







+
+
+













-
-
-
+
+
+
+
+
+
+
+
+



+
+
-
-
+
+
+
+








-
+

-
+





-
+





# Copyright (c) P.J.Gawthrop, 1997.

###############################################################
## Version control history
###############################################################
## $Id$
## $Log$
# Revision 1.1  1997/04/15  09:49:04  peterg
# Initial revision
#
###############################################################


# Inform user
echo "Creating $1_struc.tex"

rm -f mtt_error

#Write some file headers
echo "%% Structure file ($1_struc.txt)" > $1_struc.tex
echo "%% Generated by MTT at `date`" >> $1_struc.tex

# This is the main transformation using gawk
gawk '
function header(){
  print "\\begin{tabular}{l|l|l}";
sed 's/_/\\_/g' < $1_struc.txt |  gawk '
function header(what){
#  print "\\begin{table}[htbp]";
  print "  \\centering";
  print "  \\bottomcaption{" what "}";
  print "  \\begin{supertabular}{|l|l|l|l|}";
  print "    \\hline";
  print "    Index & Component & System & Repetition \\\\";
  print "    \\hline";
}

function footer(what){
  print "    \\hline";
  print "  \\end{supertabular}";
  print "\\caption{" what "}";
  print "\\end{tabular}"
#  print "  \\caption{" what "}";
#  print "\\end{table}";
  print "   \\bigskip";
  print "   \\bigskip";
}

BEGIN{
Which=""
}
{
  if ($1!=Which) {
    if (Which!="") footer(Which);
    header();
    header($1);
  }
  print $2, $3, $4;
  print $2, "&", $3,"&", $4, "&", $5, "\\\\";
  Which = $1;
}
END{
  footer(Which)
}
' < $1_struc.txt >> $1_struc.tex 2>mtt_error.txt
'  >> $1_struc.tex 2>mtt_error.txt

# Now invoke the standard error handling.
#mtt_error mtt_error.txt



MTT: Model Transformation Tools
GitHub | SourceHut | Sourceforge | Fossil RSS ]