Hopefully fix inline-block positioning. (Stops form elements from overlapping.)

svn path=/trunk/netsurf/; revision=3778
This commit is contained in:
Michael Drake 2008-01-27 11:59:01 +00:00
parent 252aa870f8
commit 053f2f830c

View File

@ -1500,12 +1500,16 @@ bool layout_line(struct box *first, int *width, int *y,
}
for (d = first; d != b; d = d->next) {
if (d->type == BOX_INLINE || d->type == BOX_INLINE_BLOCK ||
d->type == BOX_BR || d->type == BOX_TEXT ||
if (d->type == BOX_INLINE || d->type == BOX_BR ||
d->type == BOX_TEXT ||
d->type == BOX_INLINE_END) {
d->x += x0;
d->y = *y - d->padding[TOP];
}
if (d->type == BOX_INLINE_BLOCK) {
d->x += x0;
d->y = *y + d->border[TOP];
}
if (d->type == BOX_INLINE_BLOCK &&
(d->style->position == CSS_POSITION_ABSOLUTE ||
d->style->position == CSS_POSITION_FIXED))