diff options
Diffstat (limited to 'dw/textblock_linebreaking.cc')
-rw-r--r-- | dw/textblock_linebreaking.cc | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/dw/textblock_linebreaking.cc b/dw/textblock_linebreaking.cc index 2e2a23c9..4e37104b 100644 --- a/dw/textblock_linebreaking.cc +++ b/dw/textblock_linebreaking.cc @@ -916,7 +916,12 @@ void Textblock::rewrap () calcWidgetSize (word->content.widget, &word->size); wordWrap (i, false); - + + // wordWrap() may insert some new words; since NotSoSimleVector + // is used for the words list, the internal structure may have + // changed, so getRef() must be called again. + word = words->getRef (i); + if (word->content.type == core::Content::WIDGET) { word->content.widget->parentRef = lines->size () - 1; } |