X-Git-Url: https://git.cameronkatri.com/mandoc.git/blobdiff_plain/59221c379641a8d3a180c8b0cca2022c763c2a6b..0fe0edf89487fb5d13d2cd07f35eecdb45e87af7:/mdoc.h diff --git a/mdoc.h b/mdoc.h index 69a11005..9c22c336 100644 --- a/mdoc.h +++ b/mdoc.h @@ -1,4 +1,4 @@ -/* $Id: mdoc.h,v 1.110 2010/12/24 14:00:40 kristaps Exp $ */ +/* $Id: mdoc.h,v 1.114 2011/01/01 12:18:37 kristaps Exp $ */ /* * Copyright (c) 2008, 2009, 2010 Kristaps Dzonsons * @@ -190,6 +190,7 @@ enum mdoc_type { MDOC_TAIL, MDOC_BODY, MDOC_BLOCK, + MDOC_TBL, MDOC_ROOT }; @@ -353,6 +354,10 @@ struct mdoc_an { enum mdoc_auth auth; /* -split, etc. */ }; +struct mdoc_rs { + struct mdoc_node *child_J; /* pointer to %J */ +}; + /* * Consists of normalised node arguments. These should be used instead * of iterating through the mdoc_arg pointers of a node: defaults are @@ -363,6 +368,7 @@ union mdoc_data { struct mdoc_bd Bd; struct mdoc_bf Bf; struct mdoc_bl Bl; + struct mdoc_rs Rs; }; /* @@ -380,7 +386,6 @@ struct mdoc_node { enum mdoct tok; /* tok or MDOC__MAX if none */ int flags; #define MDOC_VALID (1 << 0) /* has been validated */ -#define MDOC_ACTED (1 << 1) /* has been acted upon */ #define MDOC_EOS (1 << 2) /* at sentence boundary */ #define MDOC_LINE (1 << 3) /* first macro/text on line */ #define MDOC_SYNPRETTY (1 << 4) /* SYNOPSIS-style formatting */ @@ -395,6 +400,7 @@ struct mdoc_node { struct mdoc_node *body; /* BLOCK */ struct mdoc_node *tail; /* BLOCK */ char *string; /* TEXT */ + const struct tbl_span *span; /* TBL */ enum mdoc_endbody end; /* BODY */ }; @@ -422,6 +428,8 @@ int mdoc_parseln(struct mdoc *, int, char *, int); const struct mdoc_node *mdoc_node(const struct mdoc *); const struct mdoc_meta *mdoc_meta(const struct mdoc *); int mdoc_endparse(struct mdoc *); +int mdoc_addspan(struct mdoc *, + const struct tbl_span *); __END_DECLS