70f43d63b9
Provided in PR 13059 by Ben Collver (collver@linuxfreemail.com) Texi2roff is an unmaintained program program to convert Texinfo to troff. Beverly Erlebacher wrote the program and made the last release in the late 1980's. William Bader produced a patch in 1996 adding numerous commands and other functionality. Alain Knaff added a translation table to generate man pages, and uses it to generate the manuals for mtools. Ben Collver integrated William Bader's and Alain Knaff's changes and made minor cleanups.
54 lines
1.3 KiB
Text
54 lines
1.3 KiB
Text
$NetBSD: patch-ag,v 1.1.1.1 2001/05/30 11:45:41 agc Exp $
|
|
|
|
--- items.c.orig Mon May 28 11:39:14 2001
|
|
+++ items.c Mon May 28 12:19:28 2001
|
|
@@ -14,6 +14,7 @@
|
|
#define ENUMERATE 1
|
|
#define TABLE 2
|
|
#define APPLY 3
|
|
+#define MULTITABLE 4
|
|
|
|
#define MAXILEVEL 10
|
|
int icount[MAXILEVEL];
|
|
@@ -27,8 +28,8 @@
|
|
extern struct tablerecd * lookup();
|
|
|
|
/*
|
|
- * itemize - handle the itemizing start commands @enumerate, @itemize
|
|
- * and @table
|
|
+ * itemize - handle the itemizing start commands @enumerate, @itemize,
|
|
+ * @table, and @multitable
|
|
*/
|
|
|
|
char * itemize(s, token)
|
|
@@ -58,7 +59,9 @@
|
|
} else if (STREQ(token,"@enumerate")) {
|
|
what[ilevel] = ENUMERATE;
|
|
icount[ilevel] = 1;
|
|
- } else if (STREQ(token,"@table")) {
|
|
+ } else if (STREQ(token,"@table") ||
|
|
+ STREQ(token,"@ftable") ||
|
|
+ STREQ(token,"@vtable")) {
|
|
what[ilevel] = TABLE;
|
|
s = gettoken(eatwhitespace(s),tag);
|
|
if (*tag == '\n') {
|
|
@@ -75,6 +78,11 @@
|
|
}
|
|
}
|
|
}
|
|
+ } else if (STREQ(token,"@multitable")) {
|
|
+ what[ilevel] = MULTITABLE;
|
|
+ icount[ilevel] = 1;
|
|
+ } else {
|
|
+ errormsg("unrecognized itemizing command ",token);
|
|
}
|
|
while (*s != '\n' && *s != '\0')
|
|
++s; /* flush rest of line */
|
|
@@ -98,6 +106,7 @@
|
|
(void) sprintf(tag, "%d.", icount[ilevel]++);
|
|
break;
|
|
case TABLE:
|
|
+ case MULTITABLE:
|
|
s = eatwhitespace(s);
|
|
if (*s == '\n') {
|
|
*tag++ = '-';
|