Remove unused line_height stuff for now.
svn path=/trunk/netsurf/; revision=6354
This commit is contained in:
parent
3cffe17cc7
commit
f1c7c7f072
|
@ -102,7 +102,6 @@ struct box * box_create(struct css_style *style,
|
||||||
box->parent = NULL;
|
box->parent = NULL;
|
||||||
box->fallback = NULL;
|
box->fallback = NULL;
|
||||||
box->inline_end = NULL;
|
box->inline_end = NULL;
|
||||||
box->line_height = 0;
|
|
||||||
box->float_children = NULL;
|
box->float_children = NULL;
|
||||||
box->float_container = NULL;
|
box->float_container = NULL;
|
||||||
box->next_float = NULL;
|
box->next_float = NULL;
|
||||||
|
@ -577,9 +576,6 @@ void box_dump(FILE *stream, struct box *box, unsigned int depth)
|
||||||
fprintf(stream, " ");
|
fprintf(stream, " ");
|
||||||
|
|
||||||
fprintf(stream, "%p ", box);
|
fprintf(stream, "%p ", box);
|
||||||
if (box->type == BOX_INLINE || box->type == BOX_TEXT ||
|
|
||||||
box->type == BOX_INLINE_END)
|
|
||||||
fprintf(stream, "lh%i ", box->line_height);
|
|
||||||
fprintf(stream, "x%i y%i w%i h%i ", box->x, box->y,
|
fprintf(stream, "x%i y%i w%i h%i ", box->x, box->y,
|
||||||
box->width, box->height);
|
box->width, box->height);
|
||||||
if (box->max_width != UNKNOWN_MAX_WIDTH)
|
if (box->max_width != UNKNOWN_MAX_WIDTH)
|
||||||
|
|
|
@ -201,7 +201,6 @@ struct box {
|
||||||
* corresponding to this INLINE_END box. */
|
* corresponding to this INLINE_END box. */
|
||||||
struct box *inline_end;
|
struct box *inline_end;
|
||||||
bool inline_new_line;
|
bool inline_new_line;
|
||||||
int line_height;
|
|
||||||
|
|
||||||
/** First float child box, or 0. Float boxes are in the tree twice, in
|
/** First float child box, or 0. Float boxes are in the tree twice, in
|
||||||
* this list for the block box which defines the area for floats, and
|
* this list for the block box which defines the area for floats, and
|
||||||
|
|
|
@ -1420,7 +1420,6 @@ bool layout_inline_container(struct box *inline_container, int width,
|
||||||
if ((!c->object && c->text && (c->length || is_pre)) ||
|
if ((!c->object && c->text && (c->length || is_pre)) ||
|
||||||
c->type == BOX_BR)
|
c->type == BOX_BR)
|
||||||
has_text_children = true;
|
has_text_children = true;
|
||||||
c->line_height = 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/** \todo fix wrapping so that a box with horizontal scrollbar will
|
/** \todo fix wrapping so that a box with horizontal scrollbar will
|
||||||
|
@ -2131,16 +2130,6 @@ bool layout_line(struct box *first, int *width, int *y,
|
||||||
(d->style->position == CSS_POSITION_ABSOLUTE ||
|
(d->style->position == CSS_POSITION_ABSOLUTE ||
|
||||||
d->style->position == CSS_POSITION_FIXED))
|
d->style->position == CSS_POSITION_FIXED))
|
||||||
continue;
|
continue;
|
||||||
if (d->type == BOX_INLINE && d->inline_end &&
|
|
||||||
d->next != d->inline_end) {
|
|
||||||
if (d->height > d->inline_end->line_height)
|
|
||||||
d->inline_end->line_height = d->height;
|
|
||||||
for (struct box *il = d; il && il != d->inline_end;
|
|
||||||
il = il->next) {
|
|
||||||
if (d->height > il->line_height)
|
|
||||||
il->line_height = d->height;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if ((d->type == BOX_INLINE && (d->object || d->gadget)) ||
|
if ((d->type == BOX_INLINE && (d->object || d->gadget)) ||
|
||||||
d->type == BOX_INLINE_BLOCK) {
|
d->type == BOX_INLINE_BLOCK) {
|
||||||
h = d->margin[TOP] + d->border[TOP] + d->padding[TOP] +
|
h = d->margin[TOP] + d->border[TOP] + d->padding[TOP] +
|
||||||
|
@ -2149,13 +2138,10 @@ bool layout_line(struct box *first, int *width, int *y,
|
||||||
if (used_height < h)
|
if (used_height < h)
|
||||||
used_height = h;
|
used_height = h;
|
||||||
}
|
}
|
||||||
if (d->line_height > used_height)
|
if (d->type == BOX_TEXT && d->height > used_height)
|
||||||
used_height = d->line_height;
|
used_height = d->height;
|
||||||
}
|
|
||||||
|
|
||||||
/* Set the line_height for the boxes on the current line */
|
}
|
||||||
for (d = first; d != b; d = d->next)
|
|
||||||
d->line_height = used_height;
|
|
||||||
|
|
||||||
first->inline_new_line = true;
|
first->inline_new_line = true;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue