diff options
Diffstat (limited to 'sdext/source/presenter/PresenterTextView.cxx')
-rw-r--r-- | sdext/source/presenter/PresenterTextView.cxx | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/sdext/source/presenter/PresenterTextView.cxx b/sdext/source/presenter/PresenterTextView.cxx index bf2de798a72e..7b177bd266b6 100644 --- a/sdext/source/presenter/PresenterTextView.cxx +++ b/sdext/source/presenter/PresenterTextView.cxx @@ -2,7 +2,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -173,7 +173,7 @@ void PresenterTextView::SetText (const Reference<text::XText>& rxText) Reference<container::XEnumerationAccess> xParagraphAccess (rxText, UNO_QUERY); if ( ! xParagraphAccess.is()) return; - + Reference<container::XEnumeration> xParagraphs ( xParagraphAccess->createEnumeration() , UNO_QUERY); if ( ! xParagraphs.is()) @@ -248,7 +248,7 @@ void PresenterTextView::SetTextChangeBroadcaster ( void PresenterTextView::SetLocation (const css::geometry::RealPoint2D& rLocation) { maLocation = rLocation; - + for (::std::vector<SharedPresenterTextParagraph>::iterator iParagraph(maParagraphs.begin()), iEnd(maParagraphs.end()); @@ -344,7 +344,7 @@ void PresenterTextView::MoveCaret ( case AccessibleTextType::CHARACTER: nCharacterIndex += nDistance; break; - + case AccessibleTextType::WORD: { sal_Int32 nRemainingDistance (nDistance); @@ -376,7 +376,7 @@ void PresenterTextView::MoveCaret ( else { nRemainingDistance -= nDelta; - + // Move caret one character to the end of // the previous or the start of the next paragraph. pParagraph = GetParagraph(nParagraphIndex); @@ -778,7 +778,7 @@ void PresenterTextParagraph::Format ( mnVerticalOffset = nY; maWordBoundaries.clear(); maWordBoundaries.push_back(0); - + const rendering::FontMetrics aMetrics (rpFont->mxFont->getFontMetrics()); mnAscent = aMetrics.Ascent; mnDescent = aMetrics.Descent; @@ -801,7 +801,7 @@ void PresenterTextParagraph::Format ( if (aWordBoundary.endPos>aWordBoundary.startPos) AddWord(nWidth, aCurrentLine, aWordBoundary.endPos, rpFont); - + if (aWordBoundary.startPos<0 || aWordBoundary.endPos<0) break; if (nPosition >= aWordBoundary.endPos) @@ -831,7 +831,7 @@ sal_Int32 PresenterTextParagraph::GetWordBoundary( else return GetCharacterCount(); } - + sal_Int32 nIndex (0); for (sal_Int32 nCount (maWordBoundaries.size()); nIndex<nCount; ++nIndex) { @@ -922,7 +922,7 @@ void PresenterTextParagraph::AddWord ( nLineStart = rCurrentLine.startPos; nLineEnd = rCurrentLine.endPos; } - + const ::rtl::OUString sLineCandidate ( msParagraphText.copy(nLineStart, nWordBoundary-nLineStart)); @@ -1077,7 +1077,7 @@ TextSegment PresenterTextParagraph::GetTextSegment ( if (mxBreakIterator.is()) return GetWordTextSegment(nOffset, nIndex); break; - + case AccessibleTextType::LINE: { for (::std::vector<Line>::const_iterator |