version 1.243, 2017/07/06 22:59:48 |
version 1.249, 2018/08/16 13:54:06 |
|
|
/* $Id$ */ |
/* $Id$ */ |
/* |
/* |
* Copyright (c) 2010, 2011, 2014 Kristaps Dzonsons <kristaps@bsd.lv> |
* Copyright (c) 2010, 2011, 2014 Kristaps Dzonsons <kristaps@bsd.lv> |
* Copyright (c) 2010-2017 Ingo Schwarze <schwarze@openbsd.org> |
* Copyright (c) 2010-2018 Ingo Schwarze <schwarze@openbsd.org> |
* |
* |
* Permission to use, copy, modify, and distribute this software for any |
* Permission to use, copy, modify, and distribute this software for any |
* purpose with or without fee is hereby granted, provided that the above |
* purpose with or without fee is hereby granted, provided that the above |
|
|
MANDOCERR_STYLE, /* ===== start of style suggestions ===== */ |
MANDOCERR_STYLE, /* ===== start of style suggestions ===== */ |
|
|
MANDOCERR_DATE_LEGACY, /* legacy man(7) date format: Dd ... */ |
MANDOCERR_DATE_LEGACY, /* legacy man(7) date format: Dd ... */ |
|
MANDOCERR_DATE_NORM, /* normalizing date format to: ... */ |
MANDOCERR_TITLE_CASE, /* lower case character in document title */ |
MANDOCERR_TITLE_CASE, /* lower case character in document title */ |
MANDOCERR_RCS_REP, /* duplicate RCS id: ... */ |
MANDOCERR_RCS_REP, /* duplicate RCS id: ... */ |
MANDOCERR_SEC_TYPO, /* typo in section name: Sh ... */ |
MANDOCERR_SEC_TYPO, /* possible typo in section name: Sh ... */ |
MANDOCERR_ARG_QUOTE, /* unterminated quoted argument */ |
MANDOCERR_ARG_QUOTE, /* unterminated quoted argument */ |
MANDOCERR_MACRO_USELESS, /* useless macro: macro */ |
MANDOCERR_MACRO_USELESS, /* useless macro: macro */ |
MANDOCERR_BX, /* consider using OS macro: macro */ |
MANDOCERR_BX, /* consider using OS macro: macro */ |
|
|
MANDOCERR_DELIM_NB, /* no blank before trailing delimiter: macro ... */ |
MANDOCERR_DELIM_NB, /* no blank before trailing delimiter: macro ... */ |
MANDOCERR_FI_SKIP, /* fill mode already enabled, skipping: fi */ |
MANDOCERR_FI_SKIP, /* fill mode already enabled, skipping: fi */ |
MANDOCERR_NF_SKIP, /* fill mode already disabled, skipping: nf */ |
MANDOCERR_NF_SKIP, /* fill mode already disabled, skipping: nf */ |
|
MANDOCERR_DASHDASH, /* verbatim "--", maybe consider using \(em */ |
MANDOCERR_FUNC, /* function name without markup: name() */ |
MANDOCERR_FUNC, /* function name without markup: name() */ |
MANDOCERR_SPACE_EOL, /* whitespace at end of input line */ |
MANDOCERR_SPACE_EOL, /* whitespace at end of input line */ |
MANDOCERR_COMMENT_BAD, /* bad comment style */ |
MANDOCERR_COMMENT_BAD, /* bad comment style */ |
Line 334 struct tbl_span { |
|
Line 336 struct tbl_span { |
|
}; |
}; |
|
|
enum eqn_boxt { |
enum eqn_boxt { |
EQN_ROOT, /* root of parse tree */ |
|
EQN_TEXT, /* text (number, variable, whatever) */ |
EQN_TEXT, /* text (number, variable, whatever) */ |
EQN_SUBEXPR, /* nested `eqn' subexpression */ |
EQN_SUBEXPR, /* nested `eqn' subexpression */ |
EQN_LIST, /* list (braces, etc.) */ |
EQN_LIST, /* list (braces, etc.) */ |
Line 403 struct eqn_box { |
|
Line 404 struct eqn_box { |
|
}; |
}; |
|
|
/* |
/* |
* An equation consists of a tree of expressions starting at a given |
|
* line and position. |
|
*/ |
|
struct eqn { |
|
char *name; /* identifier (or NULL) */ |
|
struct eqn_box *root; /* root mathematical expression */ |
|
int ln; /* invocation line */ |
|
int pos; /* invocation position */ |
|
}; |
|
|
|
/* |
|
* Parse options. |
* Parse options. |
*/ |
*/ |
#define MPARSE_MDOC 1 /* assume -mdoc */ |
#define MPARSE_MDOC 1 /* assume -mdoc */ |
Line 441 enum mandoc_esc { |
|
Line 431 enum mandoc_esc { |
|
ESCAPE_FONTPREV, /* previous font mode */ |
ESCAPE_FONTPREV, /* previous font mode */ |
ESCAPE_NUMBERED, /* a numbered glyph */ |
ESCAPE_NUMBERED, /* a numbered glyph */ |
ESCAPE_UNICODE, /* a unicode codepoint */ |
ESCAPE_UNICODE, /* a unicode codepoint */ |
|
ESCAPE_DEVICE, /* print the output device name */ |
ESCAPE_BREAK, /* break the output line */ |
ESCAPE_BREAK, /* break the output line */ |
ESCAPE_NOSPACE, /* suppress space if the last on a line */ |
ESCAPE_NOSPACE, /* suppress space if the last on a line */ |
ESCAPE_HORIZ, /* horizontal movement */ |
ESCAPE_HORIZ, /* horizontal movement */ |