Return to mdoc_term.c CVS log | Up to [cvsweb.bsd.lv] / mandoc |
version 1.362, 2017/06/07 17:38:26 | version 1.363, 2017/06/08 12:54:58 | ||
---|---|---|---|
|
|
||
a2width(const struct termp *p, const char *v) | a2width(const struct termp *p, const char *v) | ||
{ | { | ||
struct roffsu su; | struct roffsu su; | ||
const char *end; | |||
if (a2roffsu(v, &su, SCALE_MAX) < 2) { | end = a2roffsu(v, &su, SCALE_MAX); | ||
if (end == NULL || *end != '\0') { | |||
SCALE_HS_INIT(&su, term_strlen(p, v)); | SCALE_HS_INIT(&su, term_strlen(p, v)); | ||
su.scale /= term_strlen(p, "0"); | su.scale /= term_strlen(p, "0"); | ||
} | } |