version 1.139, 2013/12/22 23:34:13 |
version 1.141, 2014/03/08 15:50:41 |
|
|
/* $Id$ */ |
/* $Id$ */ |
/* |
/* |
* Copyright (c) 2008-2012 Kristaps Dzonsons <kristaps@bsd.lv> |
* Copyright (c) 2008-2012 Kristaps Dzonsons <kristaps@bsd.lv> |
* Copyright (c) 2010, 2011, 2012, 2013 Ingo Schwarze <schwarze@openbsd.org> |
* Copyright (c) 2010-2014 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 |
Line 658 pre_IP(DECL_ARGS) |
|
Line 658 pre_IP(DECL_ARGS) |
|
return(0); |
return(0); |
case (MAN_BODY): |
case (MAN_BODY): |
p->offset = mt->offset + len; |
p->offset = mt->offset + len; |
p->rmargin = p->maxrmargin; |
p->rmargin = p->maxrmargin > p->offset ? |
|
p->maxrmargin : p->offset; |
break; |
break; |
default: |
default: |
break; |
break; |
Line 719 pre_TP(DECL_ARGS) |
|
Line 720 pre_TP(DECL_ARGS) |
|
/* Calculate offset. */ |
/* Calculate offset. */ |
|
|
if (NULL != (nn = n->parent->head->child)) |
if (NULL != (nn = n->parent->head->child)) |
if (nn->string && nn->parent->line == nn->line) |
if (nn->string && 0 == (MAN_LINE & nn->flags)) |
if ((ival = a2width(p, nn->string)) >= 0) |
if ((ival = a2width(p, nn->string)) >= 0) |
len = (size_t)ival; |
len = (size_t)ival; |
|
|
Line 736 pre_TP(DECL_ARGS) |
|
Line 737 pre_TP(DECL_ARGS) |
|
mt->fl &= ~MANT_LITERAL; |
mt->fl &= ~MANT_LITERAL; |
|
|
/* Don't print same-line elements. */ |
/* Don't print same-line elements. */ |
for (nn = n->child; nn; nn = nn->next) |
nn = n->child; |
if (nn->line > n->line) |
while (NULL != nn && 0 == (MAN_LINE & nn->flags)) |
print_man_node(p, mt, nn, meta); |
nn = nn->next; |
|
|
|
while (NULL != nn) { |
|
print_man_node(p, mt, nn, meta); |
|
nn = nn->next; |
|
} |
|
|
if (savelit) |
if (savelit) |
mt->fl |= MANT_LITERAL; |
mt->fl |= MANT_LITERAL; |
if (ival >= 0) |
if (ival >= 0) |
Line 748 pre_TP(DECL_ARGS) |
|
Line 754 pre_TP(DECL_ARGS) |
|
return(0); |
return(0); |
case (MAN_BODY): |
case (MAN_BODY): |
p->offset = mt->offset + len; |
p->offset = mt->offset + len; |
p->rmargin = p->maxrmargin; |
p->rmargin = p->maxrmargin > p->offset ? |
|
p->maxrmargin : p->offset; |
p->trailspace = 0; |
p->trailspace = 0; |
p->flags &= ~TERMP_NOBREAK; |
p->flags &= ~TERMP_NOBREAK; |
break; |
break; |
Line 909 pre_RS(DECL_ARGS) |
|
Line 916 pre_RS(DECL_ARGS) |
|
sz = (size_t)ival; |
sz = (size_t)ival; |
|
|
mt->offset += sz; |
mt->offset += sz; |
p->rmargin = p->maxrmargin; |
p->offset = mt->offset; |
p->offset = mt->offset < p->rmargin ? mt->offset : p->rmargin; |
p->rmargin = p->maxrmargin > p->offset ? |
|
p->maxrmargin : p->offset; |
|
|
if (++mt->lmarginsz < MAXMARGINS) |
if (++mt->lmarginsz < MAXMARGINS) |
mt->lmargincur = mt->lmarginsz; |
mt->lmargincur = mt->lmarginsz; |