summaryrefslogtreecommitdiff
path: root/svtools
diff options
context:
space:
mode:
authorIvo Hinkelmann <ihi@openoffice.org>2006-08-04 09:53:15 +0000
committerIvo Hinkelmann <ihi@openoffice.org>2006-08-04 09:53:15 +0000
commit456b8a8978a834158bc52e9df7cef2a2d71917cc (patch)
tree9e8051bcc66169c1c42e3dd696d881e3b4210f1b /svtools
parent5d83331989f761b51c27685b5ad87704feb7a1d0 (diff)
INTEGRATION: CWS ab27 (1.50.62); FILE MERGED
2006/07/21 11:56:50 mt 1.50.62.1: #i63506# Check word boundary after call to previosWord
Diffstat (limited to 'svtools')
-rw-r--r--svtools/source/edit/textview.cxx7
1 files changed, 4 insertions, 3 deletions
diff --git a/svtools/source/edit/textview.cxx b/svtools/source/edit/textview.cxx
index 7e5101a3b673..f300e0e0aed5 100644
--- a/svtools/source/edit/textview.cxx
+++ b/svtools/source/edit/textview.cxx
@@ -4,9 +4,9 @@
*
* $RCSfile: textview.cxx,v $
*
- * $Revision: 1.50 $
+ * $Revision: 1.51 $
*
- * last change: $Author: hr $ $Date: 2006-06-19 21:03:00 $
+ * last change: $Author: ihi $ $Date: 2006-08-04 10:53:15 $
*
* The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1.
@@ -1462,7 +1462,8 @@ TextPaM TextView::ImpDelete( BYTE nMode, BYTE nDelMode )
i18n::Boundary aBoundary = xBI->getWordBoundary( pNode->GetText(), mpImpl->maSelection.GetEnd().GetIndex(), mpImpl->mpTextEngine->GetLocale(), i18n::WordType::ANYWORD_IGNOREWHITESPACES, sal_True );
if ( aBoundary.startPos == mpImpl->maSelection.GetEnd().GetIndex() )
aBoundary = xBI->previousWord( pNode->GetText(), mpImpl->maSelection.GetEnd().GetIndex(), mpImpl->mpTextEngine->GetLocale(), i18n::WordType::ANYWORD_IGNOREWHITESPACES );
- aEndPaM.GetIndex() = (USHORT)aBoundary.startPos;
+ // #i63506# startPos is -1 when the paragraph starts with a tab
+ aEndPaM.GetIndex() = (aBoundary.startPos >= 0) ? (USHORT)aBoundary.startPos : 0;
}
else // DELMODE_RESTOFCONTENT
{