=================================================================== RCS file: /cvs/mandoc/term.h,v retrieving revision 1.5 retrieving revision 1.6 diff -u -p -r1.5 -r1.6 --- mandoc/term.h 2009/02/24 16:16:45 1.5 +++ mandoc/term.h 2009/02/25 12:09:20 1.6 @@ -1,4 +1,4 @@ -/* $Id: term.h,v 1.5 2009/02/24 16:16:45 kristaps Exp $ */ +/* $Id: term.h,v 1.6 2009/02/25 12:09:20 kristaps Exp $ */ /* * Copyright (c) 2008 Kristaps Dzonsons * @@ -40,11 +40,27 @@ struct termp { char *buf; }; +struct termpair { + int type; +#define TERMPAIR_FLAG (1 << 0) + union { + int flag; + } data; +}; + +#define TERMPAIR_SETFLAG(p, fl) \ + do { \ + (p)->data.flag = (fl); \ + (p)->type = TERMPAIR_FLAG; \ + } while (0) + struct termact { int (*pre)(struct termp *, + struct termpair *, const struct mdoc_meta *, const struct mdoc_node *); void (*post)(struct termp *, + struct termpair *, const struct mdoc_meta *, const struct mdoc_node *); };