version 1.8, 2009/10/08 23:00:15 |
version 1.10, 2009/10/13 10:57:25 |
|
|
#include "out.h" |
#include "out.h" |
#include "html.h" |
#include "html.h" |
#include "man.h" |
#include "man.h" |
|
#include "main.h" |
|
|
/* TODO: preserve ident widths. */ |
/* TODO: preserve ident widths. */ |
|
|
Line 60 static int man_HP_pre(MAN_ARGS); |
|
Line 61 static int man_HP_pre(MAN_ARGS); |
|
static int man_I_pre(MAN_ARGS); |
static int man_I_pre(MAN_ARGS); |
static int man_IP_pre(MAN_ARGS); |
static int man_IP_pre(MAN_ARGS); |
static int man_PP_pre(MAN_ARGS); |
static int man_PP_pre(MAN_ARGS); |
|
static int man_RS_pre(MAN_ARGS); |
static int man_SB_pre(MAN_ARGS); |
static int man_SB_pre(MAN_ARGS); |
static int man_SH_pre(MAN_ARGS); |
static int man_SH_pre(MAN_ARGS); |
static int man_SM_pre(MAN_ARGS); |
static int man_SM_pre(MAN_ARGS); |
Line 99 static const struct htmlman mans[MAN_MAX] = { |
|
Line 101 static const struct htmlman mans[MAN_MAX] = { |
|
{ NULL, NULL }, /* fi */ |
{ NULL, NULL }, /* fi */ |
{ NULL, NULL }, /* r */ |
{ NULL, NULL }, /* r */ |
{ NULL, NULL }, /* RE */ |
{ NULL, NULL }, /* RE */ |
{ NULL, NULL }, /* RS */ |
{ man_RS_pre, NULL }, /* RS */ |
{ man_ign_pre, NULL }, /* DT */ |
{ man_ign_pre, NULL }, /* DT */ |
{ man_ign_pre, NULL }, /* UC */ |
{ man_ign_pre, NULL }, /* UC */ |
}; |
}; |
Line 565 man_IP_pre(MAN_ARGS) |
|
Line 567 man_IP_pre(MAN_ARGS) |
|
|
|
if (MAN_BLOCK == n->type) { |
if (MAN_BLOCK == n->type) { |
bufcat_su(h, "margin-left", &su); |
bufcat_su(h, "margin-left", &su); |
|
SCALE_VS_INIT(&su, 1); |
|
bufcat_su(h, "margin-top", &su); |
bufcat_style(h, "clear", "both"); |
bufcat_style(h, "clear", "both"); |
PAIR_STYLE_INIT(&tag, h); |
PAIR_STYLE_INIT(&tag, h); |
print_otag(h, TAG_DIV, 1, &tag); |
print_otag(h, TAG_DIV, 1, &tag); |
Line 621 man_HP_pre(MAN_ARGS) |
|
Line 625 man_HP_pre(MAN_ARGS) |
|
|
|
if (MAN_BLOCK == n->type) { |
if (MAN_BLOCK == n->type) { |
bufcat_su(h, "margin-left", &su); |
bufcat_su(h, "margin-left", &su); |
|
SCALE_VS_INIT(&su, 1); |
|
bufcat_su(h, "margin-top", &su); |
bufcat_style(h, "clear", "both"); |
bufcat_style(h, "clear", "both"); |
PAIR_STYLE_INIT(&tag, h); |
PAIR_STYLE_INIT(&tag, h); |
print_otag(h, TAG_DIV, 1, &tag); |
print_otag(h, TAG_DIV, 1, &tag); |
Line 667 man_ign_pre(MAN_ARGS) |
|
Line 673 man_ign_pre(MAN_ARGS) |
|
{ |
{ |
|
|
return(0); |
return(0); |
|
} |
|
|
|
|
|
/* ARGSUSED */ |
|
static int |
|
man_RS_pre(MAN_ARGS) |
|
{ |
|
struct htmlpair tag; |
|
struct roffsu su; |
|
|
|
if (MAN_HEAD == n->type) |
|
return(0); |
|
else if (MAN_BODY == n->type) |
|
return(1); |
|
|
|
SCALE_HS_INIT(&su, INDENT); |
|
bufcat_su(h, "margin-left", &su); |
|
|
|
if (n->head->child) { |
|
SCALE_VS_INIT(&su, 1); |
|
a2width(n->head->child, &su); |
|
bufcat_su(h, "margin-top", &su); |
|
} |
|
|
|
PAIR_STYLE_INIT(&tag, h); |
|
print_otag(h, TAG_DIV, 1, &tag); |
|
return(1); |
} |
} |