summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKristaps Dzonsons <kristaps@bsd.lv>2008-12-06 19:41:41 +0000
committerKristaps Dzonsons <kristaps@bsd.lv>2008-12-06 19:41:41 +0000
commitba3705541383817037755d7981deb54f3cb5ac43 (patch)
tree37aa2eb9280b426f9f3b7e622bf2d68648fc1163
parent3e277841fd42bbe51c55b127542258aebc6cb051 (diff)
downloadmandoc-ba3705541383817037755d7981deb54f3cb5ac43.tar.gz
*** empty log message ***
-rw-r--r--html.c57
-rw-r--r--mdocml.120
-rw-r--r--mdocml.css27
-rw-r--r--mlg.c143
-rw-r--r--roff.c51
-rw-r--r--roff.h57
6 files changed, 229 insertions, 126 deletions
diff --git a/html.c b/html.c
index 137144bc..884a09e2 100644
--- a/html.c
+++ b/html.c
@@ -83,11 +83,11 @@ static int html_headtagname(struct md_mbuf *,
static int html_headtagargs(struct md_mbuf *,
const struct md_args *, int,
const int *, const char **, size_t *);
-static int html_blockbodytagname(struct md_mbuf *,
+static int html_bodytagname(struct md_mbuf *,
const struct md_args *,
int, struct htmlq *, const int *,
const char **, size_t *);
-static int html_blockbodytagargs(struct md_mbuf *,
+static int html_bodytagargs(struct md_mbuf *,
const struct md_args *, int,
const int *, const char **, size_t *);
static int html_inlinetagname(struct md_mbuf *,
@@ -409,7 +409,7 @@ html_end(struct md_mbuf *mbuf, const struct md_args *args)
/* ARGSUSED */
static int
-html_blockbodytagname(struct md_mbuf *mbuf,
+html_bodytagname(struct md_mbuf *mbuf,
const struct md_args *args, int tok, struct htmlq *q,
const int *argc, const char **argv, size_t *res)
{
@@ -417,8 +417,12 @@ html_blockbodytagname(struct md_mbuf *mbuf,
switch (tok) {
case (ROFF_Bl):
return(html_Bl_bodytagname(mbuf, q, argc, argv, res));
+ case (ROFF_Fo):
+ return(ml_nputs(mbuf, "span", 4, res));
case (ROFF_It):
return(html_It_bodytagname(mbuf, q, argc, argv, res));
+ case (ROFF_Oo):
+ return(ml_nputs(mbuf, "span", 4, res));
default:
break;
}
@@ -437,15 +441,19 @@ html_headtagname(struct md_mbuf *mbuf,
switch (tok) {
case (ROFF_It):
return(html_It_headtagname(mbuf, q, argc, argv, res));
+ case (ROFF_Fo):
+ return(ml_nputs(mbuf, "span", 4, res));
+ case (ROFF_Oo):
+ return(ml_nputs(mbuf, "span", 4, res));
case (ROFF_Sh):
- return(ml_puts(mbuf, "h1", res));
+ return(ml_nputs(mbuf, "h1", 2, res));
case (ROFF_Ss):
- return(ml_puts(mbuf, "h2", res));
+ return(ml_nputs(mbuf, "h2", 2, res));
default:
break;
}
- return(ml_puts(mbuf, "div", res));
+ return(ml_nputs(mbuf, "div", 3, res));
}
@@ -457,6 +465,10 @@ html_blocktagname(struct md_mbuf *mbuf, const struct md_args *args,
{
switch (tok) {
+ case (ROFF_Fo):
+ return(ml_nputs(mbuf, "span", 4, res));
+ case (ROFF_Oo):
+ return(ml_nputs(mbuf, "span", 4, res));
case (ROFF_It):
return(html_It_blocktagname(mbuf, q, argc, argv, res));
default:
@@ -498,7 +510,7 @@ html_headtagargs(struct md_mbuf *mbuf,
/* ARGSUSED */
static int
-html_blockbodytagargs(struct md_mbuf *mbuf,
+html_bodytagargs(struct md_mbuf *mbuf,
const struct md_args *args, int tok,
const int *argc, const char **argv, size_t *res)
{
@@ -525,7 +537,23 @@ html_inlinetagargs(struct md_mbuf *mbuf,
const int *argc, const char **argv, size_t *res)
{
- return(html_printargs(mbuf, tok, "inline", argc, argv, res));
+ if ( ! html_printargs(mbuf, tok, "inline", argc, argv, res))
+ return(0);
+
+ switch (tok) {
+ case (ROFF_Sx):
+ assert(*argv);
+ if ( ! ml_nputs(mbuf, " href=\"#", 8, res))
+ return(0);
+ if ( ! ml_putstring(mbuf, *argv, res))
+ return(0);
+ if ( ! ml_nputs(mbuf, "\"", 1, res))
+ return(0);
+ default:
+ break;
+ }
+
+ return(1);
}
@@ -537,7 +565,9 @@ html_inlinetagname(struct md_mbuf *mbuf,
switch (tok) {
case (ROFF_Pp):
- return(ml_puts(mbuf, "div", res));
+ return(ml_nputs(mbuf, "div", 3, res));
+ case (ROFF_Sx):
+ return(ml_nputs(mbuf, "a", 1, res));
default:
break;
}
@@ -579,8 +609,7 @@ html_begintag(struct md_mbuf *mbuf, void *data,
&& i < ROFF_MAXLINEARG; i++)
node->argc[i] = argc[i];
assert(i != ROFF_MAXLINEARG);
- } else
- assert(NULL == argv);
+ }
q->last = node;
@@ -595,10 +624,10 @@ html_begintag(struct md_mbuf *mbuf, void *data,
return(-1);
break;
case (MD_NS_BODY):
- if ( ! html_blockbodytagname(mbuf, args, tok,
+ if ( ! html_bodytagname(mbuf, args, tok,
q, argc, argv, &res))
return(-1);
- if ( ! html_blockbodytagargs(mbuf, args, tok,
+ if ( ! html_bodytagargs(mbuf, args, tok,
argc, argv, &res))
return(-1);
break;
@@ -646,7 +675,7 @@ html_endtag(struct md_mbuf *mbuf, void *data,
return(-1);
break;
case (MD_NS_BODY):
- if ( ! html_blockbodytagname(mbuf, args, tok,
+ if ( ! html_bodytagname(mbuf, args, tok,
q, node->argc,
(const char **)node->argv, &res))
return(-1);
diff --git a/mdocml.1 b/mdocml.1
index a964a91c..192968f4 100644
--- a/mdocml.1
+++ b/mdocml.1
@@ -30,7 +30,7 @@ The output filter name.
Write output to
.Ar outfile ,
which may be
-.Qq \-
+.Dq \-
for stdout.
.It Fl W
Print warnings to stderr.
@@ -38,7 +38,7 @@ Print warnings to stderr.
Read input from
.Ar infile ,
which may be
-.Qq \-
+.Dq \-
for stdin.
.El
.Pp
@@ -56,24 +56,24 @@ is the default filter. This filter has no additional arguments.
The XML filter creates an XML document where element names are their respective
roff macro names. Each element name has an associated
namespace, which is one of
-.Qq block ,
-.Qq head ,
-.Qq body ,
+.Dq block ,
+.Dq head ,
+.Dq body ,
or
-.Qq inline ,
+.Dq inline ,
corresponding to the display mode of a node. The document root is
always the
-.Qq mdoc
+.Dq mdoc
element, in the default namespace; the
-.Qq head
+.Dq head
namespace is for block headers (such as
.Sq .Ss
and
.Sq .Sh ) ;
the
-.Qq body
+.Dq body
namespace is for block bodies; and the
-.Qq inline
+.Dq inline
namespace is for in-line elements (such as
.Sq .Em ) .
.Ss HTML Filter
diff --git a/mdocml.css b/mdocml.css
index ec65255e..8211141a 100644
--- a/mdocml.css
+++ b/mdocml.css
@@ -3,8 +3,7 @@
font-size: small; }
div.mdoc { width: 600px; }
div.block-Sh { margin-bottom: 20px; }
- div.head-Sh { font-weight: bold;
- font-size: larger; }
+ div.head-Sh { font-weight: bold; }
div.head-Ss { font-weight: bold;
margin-top: 10px;
text-align: justify; }
@@ -17,13 +16,29 @@
span.inline-Nm { font-weight: bolder; }
span.inline-Ar { text-decoration: underline; }
span.inline-Pa { text-decoration: underline; }
- span.inline-Op:before { content: '['; }
- span.inline-Op:after { content: ']'; }
div.block-Bl { margin-top: 10px;
margin-left: 20px; }
div.inline-Pp { margin-bottom: 10px; }
+ span.inline-Sy { font-weight: bolder; }
+ span.inline-Tn { font-variant: small-caps; }
span.inline-D1 { margin-left: 20px; }
- span.inline-Qq:before { content: '\201c'; }
- span.inline-Qq:after { content: '\201d'; }
+ span.head-Fo { font-weight: bolder; }
+ span.body-Fo:before { content: '('; }
+ span.body-Fo:after { content: ')'; }
+ span.body-Oo:before { content: '['; }
+ span.body-Oo:after { content: ']'; }
+ span.inline-Em { font-style: italic; }
+ span.inline-Op:before { content: '['; }
+ span.inline-Op:after { content: ']'; }
+ span.inline-Qq:before { content: '\"'; }
+ span.inline-Qq:after { content: '\"'; }
+ span.inline-Bq:before { content: '['; }
+ span.inline-Bq:after { content: ']'; }
+ span.inline-Dq:before { content: '\201c'; }
+ span.inline-Dq:after { content: '\201d'; }
+ span.inline-Pq:before { content: '('; }
+ span.inline-Pq:after { content: ')'; }
+ span.inline-Ql:before { content: '\2018'; }
+ span.inline-Ql:after { content: '\2019'; }
span.inline-Sq:before { content: '\2018'; }
span.inline-Sq:after { content: '\2019'; }
diff --git a/mlg.c b/mlg.c
index c8b98b9d..d5257905 100644
--- a/mlg.c
+++ b/mlg.c
@@ -60,6 +60,8 @@ struct md_mlg {
};
+static char *mlg_literal(int);
+static char *mlg_At_literal(const char *);
static void mlg_roffmsg(void *arg, enum roffmsg,
const char *, const char *, char *);
static int mlg_roffhead(void *, const struct tm *,
@@ -105,6 +107,55 @@ extern size_t strlcpy(char *, const char *, size_t);
#endif
+static char *
+mlg_At_literal(const char *p)
+{
+ if (NULL == p)
+ return("AT&amp;T UNIX");
+ if (0 == strcmp(p, "v6"))
+ return("Version 6 AT&amp;T UNIX");
+ else if (0 == strcmp(p, "v7"))
+ return("Version 7 AT&amp;T UNIX");
+ else if (0 == strcmp(p, "32v"))
+ return("Version 32v AT&amp;T UNIX");
+ else if (0 == strcmp(p, "V.1"))
+ return("AT&amp;T System V.1 UNIX");
+ else if (0 == strcmp(p, "V.4"))
+ return("AT&amp;T System V.4 UNIX");
+
+ abort();
+ /* NOTREACHED */
+}
+
+
+static char *
+mlg_literal(int tok)
+{
+ switch (tok) {
+ case (ROFF_Bt):
+ return("is currently in beta test.");
+ case (ROFF_Ud):
+ return("currently under development.");
+ case (ROFF_Fx):
+ return("FreeBSD");
+ case (ROFF_Nx):
+ return("NetBSD");
+ case (ROFF_Ox):
+ return("OpenBSD");
+ case (ROFF_Ux):
+ return("UNIX");
+ case (ROFF_Bx):
+ return("BSD");
+ case (ROFF_Bsx):
+ return("BSDI BSD/OS");
+ default:
+ break;
+ }
+ abort();
+ /* NOTREACHED */
+}
+
+
static int
mlg_begintag(struct md_mlg *p, enum md_ns ns, int tok,
int *argc, char **argv)
@@ -425,25 +476,34 @@ mlg_roffspecial(void *arg, int tok, const char *start, char **more)
assert(arg);
p = (struct md_mlg *)arg;
+ /*
+ * First handle macros without content.
+ */
+
switch (tok) {
- case (ROFF_Bt):
- assert(NULL == *more);
- if ( ! mlg_begintag(p, MD_NS_INLINE, tok, NULL, NULL))
- return(0);
- if ( ! ml_puts(p->mbuf, "is currently in beta "
- "test.", &p->pos))
- return(0);
- if ( ! mlg_endtag(p, MD_NS_INLINE, tok))
- return(0);
+ case (ROFF_Ns):
+ p->flags |= ML_OVERRIDE_ONE;
+ return(1);
+ case (ROFF_Sm):
+ assert(*more);
+ if (0 == strcmp(*more, "on"))
+ p->flags |= ML_OVERRIDE_ALL;
+ else
+ p->flags &= ~ML_OVERRIDE_ALL;
+ return(1);
+ default:
break;
+ }
+
+ if ( ! mlg_begintag(p, MD_NS_INLINE, tok, NULL, more))
+ return(0);
+ switch (tok) {
case (ROFF_Xr):
if ( ! *more) {
mlg_err(p, start, start, "missing argument");
return(0);
}
- if ( ! mlg_begintag(p, MD_NS_INLINE, tok, NULL, NULL))
- return(0);
if ( ! ml_puts(p->mbuf, *more++, &p->pos))
return(0);
if (*more) {
@@ -458,37 +518,17 @@ mlg_roffspecial(void *arg, int tok, const char *start, char **more)
mlg_err(p, start, start, "too many arguments");
return(0);
}
- if ( ! mlg_endtag(p, MD_NS_INLINE, tok))
- return(0);
break;
-
+ case (ROFF_Sx):
+ /* FALLTHROUGH */
case (ROFF_Nm):
assert(*more);
- if ( ! mlg_begintag(p, MD_NS_INLINE, tok, NULL, NULL))
- return(0);
if ( ! ml_puts(p->mbuf, *more++, &p->pos))
return(0);
assert(NULL == *more);
- if ( ! mlg_endtag(p, MD_NS_INLINE, tok))
- return(0);
break;
-
- case (ROFF_Ns):
- p->flags |= ML_OVERRIDE_ONE;
- break;
-
- case (ROFF_Sm):
- assert(*more);
- if (0 == strcmp(*more, "on"))
- p->flags |= ML_OVERRIDE_ALL;
- else
- p->flags &= ~ML_OVERRIDE_ALL;
- break;
-
case (ROFF_Ex):
assert(*more);
- if ( ! mlg_begintag(p, MD_NS_INLINE, tok, NULL, NULL))
- return(0);
if ( ! ml_puts(p->mbuf, "The ", &p->pos))
return(0);
if ( ! mlg_begintag(p, MD_NS_INLINE, ROFF_Xr, NULL, NULL))
@@ -502,28 +542,45 @@ mlg_roffspecial(void *arg, int tok, const char *start, char **more)
"occurs.", &p->pos))
return(0);
assert(NULL == *more);
- if ( ! mlg_endtag(p, MD_NS_INLINE, tok))
+ break;
+ case (ROFF_At):
+ if ( ! ml_puts(p->mbuf, mlg_At_literal(*more), &p->pos))
return(0);
break;
-
+ case (ROFF_Bx):
+ /* FALLTHROUGH */
+ case (ROFF_Bsx):
+ /* FALLTHROUGH */
+ case (ROFF_Fx):
+ /* FALLTHROUGH */
+ case (ROFF_Nx):
+ /* FALLTHROUGH */
+ case (ROFF_Ox):
+ if ( ! ml_puts(p->mbuf, mlg_literal(tok), &p->pos))
+ return(0);
+ while (*more) {
+ if ( ! ml_nputs(p->mbuf, " ", 1, &p->pos))
+ return(0);
+ if ( ! ml_putstring(p->mbuf, *more++, &p->pos))
+ return(0);
+ }
+ break;
+ case (ROFF_Bt):
+ /* FALLTHROUGH */
case (ROFF_Ud):
+ /* FALLTHROUGH */
+ case (ROFF_Ux):
assert(NULL == *more);
- if ( ! mlg_begintag(p, MD_NS_INLINE, tok, NULL, NULL))
- return(0);
- if ( ! ml_puts(p->mbuf, "currently under "
- "development.", &p->pos))
- return(0);
- if ( ! mlg_endtag(p, MD_NS_INLINE, tok))
+ if ( ! ml_puts(p->mbuf, mlg_literal(tok), &p->pos))
return(0);
break;
-
default:
mlg_err(p, start, start, "`%s' not yet supported",
toknames[tok]);
return(0);
}
- return(1);
+ return(mlg_endtag(p, MD_NS_INLINE, tok));
}
diff --git a/roff.c b/roff.c
index 1b6e475a..16962906 100644
--- a/roff.c
+++ b/roff.c
@@ -623,6 +623,22 @@ roffspecial(struct rofftree *tree, int tok,
{
switch (tok) {
+ case (ROFF_At):
+ if (0 == sz)
+ break;
+ if (0 == strcmp(*ordp, "v6"))
+ break;
+ else if (0 == strcmp(*ordp, "v7"))
+ break;
+ else if (0 == strcmp(*ordp, "32v"))
+ break;
+ else if (0 == strcmp(*ordp, "V.1"))
+ break;
+ else if (0 == strcmp(*ordp, "V.4"))
+ break;
+ roff_err(tree, start, "invalid `At' arg");
+ return(0);
+
case (ROFF_Nm):
if (0 == sz) {
if (0 == tree->name[0]) {
@@ -635,21 +651,18 @@ roffspecial(struct rofftree *tree, int tok,
return(0);
break;
+ case (ROFF_Sx):
+ /* FALLTHROUGH*/
case (ROFF_Ex):
- if (0 == sz) {
- roff_err(tree, start, "`Ex' expects an arg");
- return(0);
- } else if (1 != sz) {
- roff_err(tree, start, "`Ex' expects one arg");
+ if (1 != sz) {
+ roff_err(tree, start, "`%s' expects one arg",
+ toknames[tok]);
return(0);
}
break;
case (ROFF_Sm):
- if (0 == sz) {
- roff_err(tree, start, "`Sm' expects an arg");
- return(0);
- } else if (1 != sz) {
+ if (1 != sz) {
roff_err(tree, start, "`Sm' expects one arg");
return(0);
}
@@ -663,6 +676,8 @@ roffspecial(struct rofftree *tree, int tok,
case (ROFF_Ud):
/* FALLTHROUGH */
+ case (ROFF_Ux):
+ /* FALLTHROUGH */
case (ROFF_Bt):
if (0 != sz) {
roff_err(tree, start, "`%s' expects no args",
@@ -963,19 +978,6 @@ roffsetname(struct rofftree *tree, char **ordp)
/* ARGSUSED */
-static int
-roff_Sm(ROFFCALL_ARGS)
-{
- char *ordp[1], *p;
-
- p = *argv++;
- *ordp = *argv;
-
- return(roffspecial(tree, tok, p, *ordp ? 1 : 0, ordp));
-}
-
-
-/* ARGSUSED */
static int
roff_Ns(ROFFCALL_ARGS)
{
@@ -1201,7 +1203,8 @@ roff_ordered(ROFFCALL_ARGS)
i = 0;
while (*argv && i < ROFF_MAXLINEARG) {
- c = rofffindcallable(*argv);
+ c = ROFF_PARSED & tokens[tok].flags ?
+ rofffindcallable(*argv) : ROFF_MAX;
if (ROFF_MAX == c && ! roffispunct(*argv)) {
ordp[i++] = *argv++;
@@ -1215,7 +1218,7 @@ roff_ordered(ROFFCALL_ARGS)
if ( ! roffspecial(tree, tok, p, (size_t)i, ordp))
return(0);
- return(roffcall(tree, c, ordp));
+ return(roffcall(tree, c, argv));
}
assert(i != ROFF_MAXLINEARG);
diff --git a/roff.h b/roff.h
index 1930daac..8de0cbb0 100644
--- a/roff.h
+++ b/roff.h
@@ -57,7 +57,6 @@ static int roff_Dd(ROFFCALL_ARGS); /* FIXME: deprecate. */
static int roff_Dt(ROFFCALL_ARGS); /* FIXME: deprecate. */
static int roff_Os(ROFFCALL_ARGS); /* FIXME: deprecate. */
static int roff_Ns(ROFFCALL_ARGS); /* FIXME: deprecate. */
-static int roff_Sm(ROFFCALL_ARGS); /* FIXME: deprecate. */
static int roff_layout(ROFFCALL_ARGS);
static int roff_text(ROFFCALL_ARGS);
static int roff_noop(ROFFCALL_ARGS);
@@ -152,53 +151,53 @@ static const struct rofftok tokens[ROFF_MAX] = {
{ roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Ac */
{ roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Ao */
{ roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE | ROFF_LSCOPE }, /* Aq */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, 0 }, /* At */ /* XXX at most 2 args */
+/*Ok*/ {roff_ordered, NULL, NULL, NULL, 0, ROFF_TEXT, 0 }, /* At */
{ roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Bc */
{ roff_layout, NULL, NULL, NULL, 0, ROFF_LAYOUT, 0 }, /* Bf */ /* FIXME */
{ roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Bo */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE | ROFF_LSCOPE }, /* Bq */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED }, /* Bsx */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED }, /* Bx */
+/*Ok*/ { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE | ROFF_LSCOPE }, /* Bq */
+/*Ok*/ {roff_ordered, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED }, /* Bsx */
+/*Ok*/ {roff_ordered, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED }, /* Bx */
{ NULL, NULL, NULL, NULL, 0, ROFF_SPECIAL, 0 }, /* Db */
{ roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Dc */
{ roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Do */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE | ROFF_LSCOPE }, /* Dq */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Ec */
+/*Ok*/ { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE | ROFF_LSCOPE }, /* Dq */
+ { NULL, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Ec */
{ roff_noop, NULL, NULL, NULL, ROFF_Bf, ROFF_LAYOUT, 0 }, /* Ef */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Em */ /* XXX needs arg */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Eo */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED }, /* Fx */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED }, /* Ms */
+/*Ok*/ { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Em */ /* XXX needs arg */
+ { NULL, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Eo */
+/*Ok*/ {roff_ordered, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED }, /* Fx */
+ { NULL, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED }, /* Ms */
{ NULL, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* No */
- { roff_Ns, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Ns */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED }, /* Nx */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED }, /* Ox */
+/*Ok*/ { roff_Ns, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Ns */
+/*Ok*/ {roff_ordered, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED }, /* Nx */
+/*Ok*/ {roff_ordered, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED }, /* Ox */
{ roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Pc */
{ NULL, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED }, /* Pf */
{ roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Po */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE | ROFF_LSCOPE }, /* Pq */
+/*Ok*/ { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE | ROFF_LSCOPE }, /* Pq */
{ roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Qc */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Ql */
+/*Ok*/ { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Ql */
{ roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Qo */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE | ROFF_LSCOPE }, /* Qq */
+/*Ok*/ { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE | ROFF_LSCOPE }, /* Qq */
{ roff_noop, NULL, roffparent_Re, NULL, ROFF_Rs, ROFF_LAYOUT, 0 }, /* Re */
{ roff_layout, NULL, NULL, roffchild_Rs, 0, ROFF_LAYOUT, 0 }, /* Rs */
{ roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Sc */
{ roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* So */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE | ROFF_LSCOPE }, /* Sq */
- { roff_Sm, NULL, NULL, NULL, 0, ROFF_TEXT, 0 }, /* Sm */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Sx */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Sy */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Tn */
- { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED }, /* Ux */
+/*Ok*/ { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE | ROFF_LSCOPE }, /* Sq */
+/*Ok*/ {roff_ordered, NULL, NULL, NULL, 0, ROFF_TEXT, 0 }, /* Sm */
+/*Ok*/ {roff_ordered, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Sx */
+/*Ok*/ { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Sy */
+/*Ok*/ { roff_text, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Tn */
+/*Ok*/ {roff_ordered, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED }, /* Ux */
{ NULL, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Xc */
{ NULL, NULL, NULL, NULL, 0, ROFF_TEXT, ROFF_PARSED | ROFF_CALLABLE }, /* Xo */
- { roff_layout, NULL, NULL, roffchild_Fo, 0, ROFF_LAYOUT, 0 }, /* Fo */
- { roff_noop, NULL, roffparent_Fc, NULL, ROFF_Fo, ROFF_LAYOUT, 0 }, /* Fc */
- { roff_layout, NULL, NULL, NULL, 0, ROFF_LAYOUT, 0 }, /* Oo */
- { roff_noop, NULL, roffparent_Oc, NULL, ROFF_Oo, ROFF_LAYOUT, 0 }, /* Oc */
- { roff_layout, roffarg_Bk, NULL, NULL, 0, ROFF_LAYOUT, 0 }, /* Bk */
- { roff_noop, NULL, NULL, NULL, ROFF_Bk, ROFF_LAYOUT, 0 }, /* Ek */
+/*Ok*/ { roff_layout, NULL, NULL, roffchild_Fo, 0, ROFF_LAYOUT, 0 }, /* Fo */ /* FIXME: section/linebreak. */
+/*Ok*/ { roff_noop, NULL, roffparent_Fc, NULL, ROFF_Fo, ROFF_LAYOUT, 0 }, /* Fc */ /* FIXME: section/linebreak. */
+/*Ok*/ { roff_layout, NULL, NULL, NULL, 0, ROFF_LAYOUT, 0 }, /* Oo */
+/*Ok*/ { roff_noop, NULL, roffparent_Oc, NULL, ROFF_Oo, ROFF_LAYOUT, 0 }, /* Oc */
+ { NULL, roffarg_Bk, NULL, NULL, 0, ROFF_LAYOUT, 0 }, /* Bk */
+ { NULL, NULL, NULL, NULL, ROFF_Bk, ROFF_LAYOUT, 0 }, /* Ek */
/*Ok*/ {roff_ordered, NULL, NULL, NULL, 0, ROFF_TEXT, 0 }, /* Bt */
{ NULL, NULL, NULL, NULL, 0, ROFF_TEXT, 0 }, /* Hf */
/*Ok*/ { roff_depr, NULL, NULL, NULL, 0, ROFF_TEXT, 0 }, /* Fr */