summaryrefslogtreecommitdiff
path: root/render/box_construct.c
diff options
context:
space:
mode:
authorMichael Drake <tlsa@netsurf-browser.org>2011-03-02 19:16:03 +0000
committerMichael Drake <tlsa@netsurf-browser.org>2011-03-02 19:16:03 +0000
commitbe366b0e6bb47fa8cc0bb8a6c310884f2cf4078f (patch)
tree11825f7b900b04a5bd7d1581682f713eaa241be6 /render/box_construct.c
parent3707be6292e5d8c93b121a698f67bb679ff8fba4 (diff)
downloadnetsurf-be366b0e6bb47fa8cc0bb8a6c310884f2cf4078f.tar.gz
netsurf-be366b0e6bb47fa8cc0bb8a6c310884f2cf4078f.tar.bz2
Move strip_leading_newline to box flags.
svn path=/trunk/netsurf/; revision=11889
Diffstat (limited to 'render/box_construct.c')
-rw-r--r--render/box_construct.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/render/box_construct.c b/render/box_construct.c
index 092edb3ba..d99e5deec 100644
--- a/render/box_construct.c
+++ b/render/box_construct.c
@@ -302,10 +302,10 @@ bool box_construct_element(xmlNode *n, struct content *content,
gui_multitask();
/* In case the parent is a pre block, we clear the
- * strip_leading_newline flag since it is not used if we
+ * PRE_STRIP flag since it is not used if we
* follow the pre with a tag
*/
- parent->strip_leading_newline = 0;
+ parent->flags &= ~PRE_STRIP;
styles = box_get_style(content, parent_style, n);
if (!styles)
@@ -824,7 +824,7 @@ bool box_construct_text(xmlNode *n, struct content *content,
current = text;
/* swallow a single leading new line */
- if (parent->strip_leading_newline) {
+ if (parent->flags & PRE_STRIP) {
switch (*current) {
case '\n':
current++; break;
@@ -833,7 +833,7 @@ bool box_construct_text(xmlNode *n, struct content *content,
if (*current == '\n') current++;
break;
}
- parent->strip_leading_newline = 0;
+ parent->flags &= ~PRE_STRIP;
}
do {
@@ -1079,7 +1079,7 @@ bool box_br(BOX_SPECIAL_PARAMS)
bool box_pre(BOX_SPECIAL_PARAMS)
{
- box->strip_leading_newline = 1;
+ box->flags |= PRE_STRIP;
return true;
}