diff options
Diffstat (limited to 'sw/source/filter/ww8/wrtw8esh.cxx')
-rw-r--r-- | sw/source/filter/ww8/wrtw8esh.cxx | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sw/source/filter/ww8/wrtw8esh.cxx b/sw/source/filter/ww8/wrtw8esh.cxx index 2e94c500cbde..fc68e76fcd0e 100644 --- a/sw/source/filter/ww8/wrtw8esh.cxx +++ b/sw/source/filter/ww8/wrtw8esh.cxx @@ -763,8 +763,10 @@ void PlcDrawObj::WritePlc( WW8Export& rWrt ) const // We have to export original size with padding const SfxItemSet& rSet = pObj->GetMergedItemSet(); - const SdrMetricItem* pItem = static_cast<const SdrMetricItem*>(rSet.GetItem(SDRATTR_TEXT_UPPERDIST)); - aRect.SetSize(Size(aRect.GetWidth(), aRect.GetHeight() + pItem->GetValue())); + long nHeight = aRect.GetHeight(); + if (const SdrMetricItem* pItem = static_cast<const SdrMetricItem*>(rSet.GetItem(SDRATTR_TEXT_UPPERDIST))) + nHeight += pItem->GetValue(); + aRect.SetSize(Size(aRect.GetWidth(), nHeight)); } } |