summaryrefslogtreecommitdiff
path: root/render/box.h
diff options
context:
space:
mode:
authorJames Bursa <james@netsurf-browser.org>2005-07-21 21:48:41 +0000
committerJames Bursa <james@netsurf-browser.org>2005-07-21 21:48:41 +0000
commit4e9457bee1dcadf9f0f20387e59edc970f42c987 (patch)
treeb8d0cd44562b91093e72238b66ae4110776cfe9a /render/box.h
parent1a1901d19b07ea265840962877b34b1205f6b092 (diff)
downloadnetsurf-4e9457bee1dcadf9f0f20387e59edc970f42c987.tar.gz
netsurf-4e9457bee1dcadf9f0f20387e59edc970f42c987.tar.bz2
[project @ 2005-07-21 21:48:41 by bursa]
Fix layout min max bug with blocks with negative margins. Add assert()s to check that 0 <= min_width <= max_width at the end of each layout_minmax_X() function. svn path=/import/netsurf/; revision=1813
Diffstat (limited to 'render/box.h')
-rw-r--r--render/box.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/render/box.h b/render/box.h
index f68720937..7eaca2622 100644
--- a/render/box.h
+++ b/render/box.h
@@ -139,9 +139,12 @@ struct box {
int scroll_x; /**< Horizontal scroll of descendants. */
int scroll_y; /**< Vertical scroll of descendants. */
- /**< Width of box taking all line breaks (including margins etc.). */
+ /** Width of box taking all line breaks (including margins etc). Must
+ * be non-negative. */
int min_width;
- int max_width; /**< Width that would be taken with no line breaks. */
+ /** Width that would be taken with no line breaks. Must be
+ * non-negative. */
+ int max_width;
/**< Byte offset within a textual representation of this content. */
size_t byte_offset;