diff options
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/view/viewsh.cxx | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/sw/source/core/view/viewsh.cxx b/sw/source/core/view/viewsh.cxx index 580117f7c05d..9a5ff25ac2bd 100644 --- a/sw/source/core/view/viewsh.cxx +++ b/sw/source/core/view/viewsh.cxx @@ -1085,12 +1085,14 @@ void SwViewShell::VisPortChgd( const SwRect &rRect) if (pObj->IsFormatPossible()) { const Rectangle &rBound = pObj->GetObjRect().SVRect(); - // OD 03.03.2003 #107927# - use correct datatype - const SwTwips nL = std::max( 0L, rBound.Left() - nOfst ); - if ( nL < nMinLeft ) - nMinLeft = nL; - if( rBound.Right() + nOfst > nMaxRight ) - nMaxRight = rBound.Right() + nOfst; + if (rBound.Left() != FAR_AWAY) { + // OD 03.03.2003 #107927# - use correct datatype + const SwTwips nL = std::max( 0L, rBound.Left() - nOfst ); + if ( nL < nMinLeft ) + nMinLeft = nL; + if( rBound.Right() + nOfst > nMaxRight ) + nMaxRight = rBound.Right() + nOfst; + } } } } |