diff options
author | Johannes Hofmann <Johannes.Hofmann@gmx.de> | 2009-01-15 09:21:14 +0100 |
---|---|---|
committer | Johannes Hofmann <Johannes.Hofmann@gmx.de> | 2009-01-15 09:21:14 +0100 |
commit | 7d3db08ea82c01ce1b7606cc2ab89d3da42adc71 (patch) | |
tree | 5786b3e5921874db7267b26ac0ebb60d4425dc08 /src/styleengine.cc | |
parent | bb71912c09b41c1daa11c10bc7b229147a022ec3 (diff) | |
parent | 650d4b39f0911aaece06415ce530aecf2c72d110 (diff) |
merge
Diffstat (limited to 'src/styleengine.cc')
-rw-r--r-- | src/styleengine.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/styleengine.cc b/src/styleengine.cc index accfbd7d..b5e2a3a4 100644 --- a/src/styleengine.cc +++ b/src/styleengine.cc @@ -23,6 +23,7 @@ StyleEngine::StyleEngine (dw::core::Layout *layout) { stack = new lout::misc::SimpleVector <Node> (1); cssContext = new CssContext (); this->layout = layout; + num = 0; stack->increase (); Node *n = stack->getRef (stack->size () - 1); @@ -37,7 +38,8 @@ StyleEngine::StyleEngine (dw::core::Layout *layout) { style_attrs.font = Font::create (layout, &font_attrs); style_attrs.color = Color::create (layout, 0); style_attrs.backgroundColor = Color::create (layout, 0xffffff); - + + n->num = num++; n->style = Style::create (layout, &style_attrs); n->wordStyle = NULL; n->pseudo = NULL; @@ -62,6 +64,7 @@ void StyleEngine::startElement (int element) { stack->increase (); Node *n = stack->getRef (stack->size () - 1); + n->num = num++; n->style = NULL; n->wordStyle = NULL; n->depth = stack->size () - 1; |