diff options
Diffstat (limited to 'sdext/source/presenter/PresenterTextView.cxx')
-rwxr-xr-x | 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 8cd308dc230f..5e941b021752 100755 --- a/sdext/source/presenter/PresenterTextView.cxx +++ b/sdext/source/presenter/PresenterTextView.cxx @@ -1,7 +1,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 @@ -172,7 +172,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()) @@ -247,7 +247,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()); @@ -343,7 +343,7 @@ void PresenterTextView::MoveCaret ( case AccessibleTextType::CHARACTER: nCharacterIndex += nDistance; break; - + case AccessibleTextType::WORD: { sal_Int32 nRemainingDistance (nDistance); @@ -375,7 +375,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); @@ -775,7 +775,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; @@ -798,7 +798,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) @@ -828,7 +828,7 @@ sal_Int32 PresenterTextParagraph::GetWordBoundary( else return GetCharacterCount(); } - + sal_Int32 nIndex (0); for (sal_Int32 nCount (maWordBoundaries.size()); nIndex<nCount; ++nIndex) { @@ -919,7 +919,7 @@ void PresenterTextParagraph::AddWord ( nLineStart = rCurrentLine.startPos; nLineEnd = rCurrentLine.endPos; } - + const ::rtl::OUString sLineCandidate ( msParagraphText.copy(nLineStart, nWordBoundary-nLineStart)); @@ -1074,7 +1074,7 @@ TextSegment PresenterTextParagraph::GetTextSegment ( if (mxBreakIterator.is()) return GetWordTextSegment(nOffset, nIndex); break; - + case AccessibleTextType::LINE: { for (::std::vector<Line>::const_iterator |