Changeset View
Changeset View
Standalone View
Standalone View
contrib/mandoc/mdoc_term.c
Show First 20 Lines • Show All 110 Lines • ▼ Show 20 Lines | |||||
static int termp_nm_pre(DECL_ARGS); | static int termp_nm_pre(DECL_ARGS); | ||||
static int termp_ns_pre(DECL_ARGS); | static int termp_ns_pre(DECL_ARGS); | ||||
static int termp_quote_pre(DECL_ARGS); | static int termp_quote_pre(DECL_ARGS); | ||||
static int termp_rs_pre(DECL_ARGS); | static int termp_rs_pre(DECL_ARGS); | ||||
static int termp_sh_pre(DECL_ARGS); | static int termp_sh_pre(DECL_ARGS); | ||||
static int termp_skip_pre(DECL_ARGS); | static int termp_skip_pre(DECL_ARGS); | ||||
static int termp_sm_pre(DECL_ARGS); | static int termp_sm_pre(DECL_ARGS); | ||||
static int termp_pp_pre(DECL_ARGS); | static int termp_pp_pre(DECL_ARGS); | ||||
static int termp_sl_pre(DECL_ARGS); | |||||
static int termp_ss_pre(DECL_ARGS); | static int termp_ss_pre(DECL_ARGS); | ||||
static int termp_sy_pre(DECL_ARGS); | static int termp_sy_pre(DECL_ARGS); | ||||
static int termp_tag_pre(DECL_ARGS); | static int termp_tag_pre(DECL_ARGS); | ||||
static int termp_under_pre(DECL_ARGS); | static int termp_under_pre(DECL_ARGS); | ||||
static int termp_vt_pre(DECL_ARGS); | static int termp_vt_pre(DECL_ARGS); | ||||
static int termp_xr_pre(DECL_ARGS); | static int termp_xr_pre(DECL_ARGS); | ||||
static int termp_xx_pre(DECL_ARGS); | static int termp_xx_pre(DECL_ARGS); | ||||
▲ Show 20 Lines • Show All 113 Lines • ▼ Show 20 Lines | static const struct mdoc_term_act mdoc_term_acts[MDOC_MAX - MDOC_Dd] = { | ||||
{ NULL, NULL }, /* Brc */ | { NULL, NULL }, /* Brc */ | ||||
{ NULL, termp____post }, /* %C */ | { NULL, termp____post }, /* %C */ | ||||
{ termp_skip_pre, NULL }, /* Es */ | { termp_skip_pre, NULL }, /* Es */ | ||||
{ termp_quote_pre, termp_quote_post }, /* En */ | { termp_quote_pre, termp_quote_post }, /* En */ | ||||
{ termp_xx_pre, termp_xx_post }, /* Dx */ | { termp_xx_pre, termp_xx_post }, /* Dx */ | ||||
{ NULL, termp____post }, /* %Q */ | { NULL, termp____post }, /* %Q */ | ||||
{ NULL, termp____post }, /* %U */ | { NULL, termp____post }, /* %U */ | ||||
{ NULL, NULL }, /* Ta */ | { NULL, NULL }, /* Ta */ | ||||
{ termp_sl_pre, NULL }, /* Sl */ | |||||
}; | }; | ||||
static int fn_prio; | static int fn_prio; | ||||
void | void | ||||
terminal_mdoc(void *arg, const struct roff_meta *mdoc) | terminal_mdoc(void *arg, const struct roff_meta *mdoc) | ||||
{ | { | ||||
▲ Show 20 Lines • Show All 1,312 Lines • ▼ Show 20 Lines | |||||
} | } | ||||
static int | static int | ||||
termp_cd_pre(DECL_ARGS) | termp_cd_pre(DECL_ARGS) | ||||
{ | { | ||||
synopsis_pre(p, n); | synopsis_pre(p, n); | ||||
term_fontpush(p, TERMFONT_BOLD); | term_fontpush(p, TERMFONT_BOLD); | ||||
return 1; | |||||
} | |||||
static int | |||||
termp_sl_pre(DECL_ARGS) | |||||
{ | |||||
synopsis_pre(p, n); | |||||
if ((n->flags & NODE_SYNPRETTY) && (n->flags & NODE_LINE)) { | |||||
term_fontpush(p, TERMFONT_BOLD); | |||||
term_word(p, "sysctl:"); | |||||
} | |||||
term_fontpush(p, TERMFONT_UNDER); | |||||
return 1; | return 1; | ||||
} | } | ||||
static int | static int | ||||
termp_in_pre(DECL_ARGS) | termp_in_pre(DECL_ARGS) | ||||
{ | { | ||||
synopsis_pre(p, n); | synopsis_pre(p, n); | ||||
▲ Show 20 Lines • Show All 505 Lines • Show Last 20 Lines |