LibreOffice Module sdext (master)  1
Classes | Public Member Functions | Private Member Functions | Private Attributes | List of all members
sdext::presenter::PresenterTextParagraph Class Reference

#include <PresenterTextView.hxx>

Classes

class  Cell
 A portion of a string that encodes one unicode cell. More...
 
class  Line
 

Public Member Functions

 PresenterTextParagraph (const sal_Int32 nParagraphIndex, const css::uno::Reference< css::i18n::XBreakIterator > &rxBreakIterator, const css::uno::Reference< css::i18n::XScriptTypeDetector > &rxScriptTypeDetector, const css::uno::Reference< css::text::XTextRange > &rxTextRange, const SharedPresenterTextCaret &rpCaret)
 
void Paint (const css::uno::Reference< css::rendering::XCanvas > &rxCanvas, const css::geometry::RealSize2D &rSize, const PresenterTheme::SharedFontDescriptor &rpFont, const css::rendering::ViewState &rViewState, css::rendering::RenderState &rRenderState, const double nTopOffset, const double nClipTop, const double nClipBottom)
 
double GetTotalTextHeight () const
 
void SetCharacterOffset (const sal_Int32 nCharacterOffset)
 
sal_Int32 GetCharacterCount () const
 
sal_Unicode GetCharacter (const sal_Int32 nGlobalCharacterIndex) const
 
const OUString & GetText () const
 
css::accessibility::TextSegment GetTextSegment (const sal_Int32 nOffset, const sal_Int32 nGlobalCharacterIndex, const sal_Int16 nTextType) const
 
css::accessibility::TextSegment GetWordTextSegment (const sal_Int32 nOffset, const sal_Int32 nIndex) const
 
css::accessibility::TextSegment CreateTextSegment (sal_Int32 nStartIndex, sal_Int32 nEndIndex) const
 
css::awt::Rectangle GetCharacterBounds (sal_Int32 nGlobalCharacterIndex, const bool bCaretBox)
 
void SetupCellArray (const PresenterTheme::SharedFontDescriptor &rpFont)
 
void Format (const double nY, const double nWidth, const PresenterTheme::SharedFontDescriptor &rpFont)
 
sal_Int32 GetWordBoundary (const sal_Int32 nLocalCharacterIndex, const sal_Int32 nDistance)
 
sal_Int32 GetCaretPosition () const
 
void SetCaretPosition (const sal_Int32 nPosition) const
 
void SetOrigin (const double nXOrigin, const double nYOrigin)
 
css::awt::Point GetRelativeLocation () const
 
css::awt::Size GetSize () const
 

Private Member Functions

void AddWord (const double nWidth, css::i18n::Boundary &rCurrentLine, const sal_Int32 nWordBoundary, const PresenterTheme::SharedFontDescriptor &rpFont)
 
void AddLine (css::i18n::Boundary &rCurrentLine)
 
sal_Int8 GetTextDirection () const
 
bool IsTextReferencePointLeft () const
 

Private Attributes

OUString msParagraphText
 
const sal_Int32 mnParagraphIndex
 
SharedPresenterTextCaret mpCaret
 
css::uno::Reference< css::i18n::XBreakIterator > mxBreakIterator
 
css::uno::Reference< css::i18n::XScriptTypeDetector > mxScriptTypeDetector
 
::std::vector< LinemaLines
 
::std::vector< sal_Int32 > maWordBoundaries
 
double mnVerticalOffset
 
double mnXOrigin
 
double mnYOrigin
 
double mnWidth
 
double mnAscent
 
double mnDescent
 
double mnLineHeight
 
sal_Int8 mnWritingMode
 
sal_Int32 mnCharacterOffset
 The index of the first character in this paragraph with respect to the whole text. More...
 
::std::vector< CellmaCells
 

Detailed Description

Definition at line 88 of file PresenterTextView.hxx.

Constructor & Destructor Documentation

sdext::presenter::PresenterTextParagraph::PresenterTextParagraph ( const sal_Int32  nParagraphIndex,
const css::uno::Reference< css::i18n::XBreakIterator > &  rxBreakIterator,
const css::uno::Reference< css::i18n::XScriptTypeDetector > &  rxScriptTypeDetector,
const css::uno::Reference< css::text::XTextRange > &  rxTextRange,
const SharedPresenterTextCaret rpCaret 
)

Definition at line 434 of file PresenterTextView.cxx.

References mnParagraphIndex, mnWidth, mnWritingMode, msParagraphText, and text().

Member Function Documentation

void sdext::presenter::PresenterTextParagraph::AddLine ( css::i18n::Boundary &  rCurrentLine)
private
void sdext::presenter::PresenterTextParagraph::AddWord ( const double  nWidth,
css::i18n::Boundary &  rCurrentLine,
const sal_Int32  nWordBoundary,
const PresenterTheme::SharedFontDescriptor rpFont 
)
private
TextSegment sdext::presenter::PresenterTextParagraph::CreateTextSegment ( sal_Int32  nStartIndex,
sal_Int32  nEndIndex 
) const

Definition at line 863 of file PresenterTextView.cxx.

References msParagraphText.

Referenced by GetTextSegment(), and GetWordTextSegment().

void sdext::presenter::PresenterTextParagraph::Format ( const double  nY,
const double  nWidth,
const PresenterTheme::SharedFontDescriptor rpFont 
)
sal_Int32 sdext::presenter::PresenterTextParagraph::GetCaretPosition ( ) const

Definition at line 629 of file PresenterTextView.cxx.

References mnParagraphIndex, and mpCaret.

sal_Unicode sdext::presenter::PresenterTextParagraph::GetCharacter ( const sal_Int32  nGlobalCharacterIndex) const

Definition at line 739 of file PresenterTextView.cxx.

References mnCharacterOffset, and msParagraphText.

awt::Rectangle sdext::presenter::PresenterTextParagraph::GetCharacterBounds ( sal_Int32  nGlobalCharacterIndex,
const bool  bCaretBox 
)
sal_Int32 sdext::presenter::PresenterTextParagraph::GetCharacterCount ( ) const

Definition at line 734 of file PresenterTextView.cxx.

References msParagraphText.

Referenced by GetWordBoundary(), and GetWordTextSegment().

awt::Point sdext::presenter::PresenterTextParagraph::GetRelativeLocation ( ) const

Definition at line 649 of file PresenterTextView.cxx.

References mnVerticalOffset, mnXOrigin, and mnYOrigin.

awt::Size sdext::presenter::PresenterTextParagraph::GetSize ( ) const

Definition at line 656 of file PresenterTextView.cxx.

References GetTotalTextHeight(), and mnWidth.

const OUString & sdext::presenter::PresenterTextParagraph::GetText ( ) const

Definition at line 753 of file PresenterTextView.cxx.

References msParagraphText.

sal_Int8 sdext::presenter::PresenterTextParagraph::GetTextDirection ( ) const
private
TextSegment sdext::presenter::PresenterTextParagraph::GetTextSegment ( const sal_Int32  nOffset,
const sal_Int32  nGlobalCharacterIndex,
const sal_Int16  nTextType 
) const
double sdext::presenter::PresenterTextParagraph::GetTotalTextHeight ( ) const

Definition at line 724 of file PresenterTextView.cxx.

References maLines, and mnLineHeight.

Referenced by GetSize().

sal_Int32 sdext::presenter::PresenterTextParagraph::GetWordBoundary ( const sal_Int32  nLocalCharacterIndex,
const sal_Int32  nDistance 
)

Definition at line 589 of file PresenterTextView.cxx.

References GetCharacterCount(), maWordBoundaries, nCount, and nIndex.

TextSegment sdext::presenter::PresenterTextParagraph::GetWordTextSegment ( const sal_Int32  nOffset,
const sal_Int32  nIndex 
) const
bool sdext::presenter::PresenterTextParagraph::IsTextReferencePointLeft ( ) const
private

Definition at line 994 of file PresenterTextView.cxx.

References mnWritingMode.

Referenced by Paint().

void sdext::presenter::PresenterTextParagraph::Paint ( const css::uno::Reference< css::rendering::XCanvas > &  rxCanvas,
const css::geometry::RealSize2D &  rSize,
const PresenterTheme::SharedFontDescriptor rpFont,
const css::rendering::ViewState rViewState,
css::rendering::RenderState &  rRenderState,
const double  nTopOffset,
const double  nClipTop,
const double  nClipBottom 
)
void sdext::presenter::PresenterTextParagraph::SetCaretPosition ( const sal_Int32  nPosition) const

Definition at line 637 of file PresenterTextView.cxx.

References mnParagraphIndex, and mpCaret.

void sdext::presenter::PresenterTextParagraph::SetCharacterOffset ( const sal_Int32  nCharacterOffset)

Definition at line 729 of file PresenterTextView.cxx.

References mnCharacterOffset.

void sdext::presenter::PresenterTextParagraph::SetOrigin ( const double  nXOrigin,
const double  nYOrigin 
)

Definition at line 643 of file PresenterTextView.cxx.

References mnXOrigin, and mnYOrigin.

void sdext::presenter::PresenterTextParagraph::SetupCellArray ( const PresenterTheme::SharedFontDescriptor rpFont)

Member Data Documentation

::std::vector<Cell> sdext::presenter::PresenterTextParagraph::maCells
private

Definition at line 198 of file PresenterTextView.hxx.

Referenced by AddLine(), and SetupCellArray().

::std::vector<Line> sdext::presenter::PresenterTextParagraph::maLines
private
::std::vector<sal_Int32> sdext::presenter::PresenterTextParagraph::maWordBoundaries
private

Definition at line 184 of file PresenterTextView.hxx.

Referenced by Format(), and GetWordBoundary().

double sdext::presenter::PresenterTextParagraph::mnAscent
private

Definition at line 191 of file PresenterTextView.hxx.

Referenced by AddLine(), Format(), GetCharacterBounds(), and Paint().

sal_Int32 sdext::presenter::PresenterTextParagraph::mnCharacterOffset
private

The index of the first character in this paragraph with respect to the whole text.

Definition at line 197 of file PresenterTextView.hxx.

Referenced by GetCharacter(), GetTextSegment(), and SetCharacterOffset().

double sdext::presenter::PresenterTextParagraph::mnDescent
private

Definition at line 192 of file PresenterTextView.hxx.

Referenced by Format(), and GetCharacterBounds().

double sdext::presenter::PresenterTextParagraph::mnLineHeight
private

Definition at line 193 of file PresenterTextView.hxx.

Referenced by AddLine(), Format(), GetCharacterBounds(), GetTotalTextHeight(), and Paint().

const sal_Int32 sdext::presenter::PresenterTextParagraph::mnParagraphIndex
private

Definition at line 144 of file PresenterTextView.hxx.

Referenced by GetCaretPosition(), and SetCaretPosition().

double sdext::presenter::PresenterTextParagraph::mnVerticalOffset
private

Definition at line 187 of file PresenterTextView.hxx.

Referenced by AddLine(), Format(), GetCharacterBounds(), and GetRelativeLocation().

double sdext::presenter::PresenterTextParagraph::mnWidth
private

Definition at line 190 of file PresenterTextView.hxx.

Referenced by Format(), and GetSize().

sal_Int8 sdext::presenter::PresenterTextParagraph::mnWritingMode
private
double sdext::presenter::PresenterTextParagraph::mnXOrigin
private

Definition at line 188 of file PresenterTextView.hxx.

Referenced by GetCharacterBounds(), GetRelativeLocation(), and SetOrigin().

double sdext::presenter::PresenterTextParagraph::mnYOrigin
private

Definition at line 189 of file PresenterTextView.hxx.

Referenced by GetCharacterBounds(), GetRelativeLocation(), and SetOrigin().

SharedPresenterTextCaret sdext::presenter::PresenterTextParagraph::mpCaret
private

Definition at line 145 of file PresenterTextView.hxx.

Referenced by GetCaretPosition(), and SetCaretPosition().

OUString sdext::presenter::PresenterTextParagraph::msParagraphText
private
css::uno::Reference<css::i18n::XBreakIterator> sdext::presenter::PresenterTextParagraph::mxBreakIterator
private

Definition at line 181 of file PresenterTextView.hxx.

Referenced by Format(), GetTextSegment(), GetWordTextSegment(), and SetupCellArray().

css::uno::Reference<css::i18n::XScriptTypeDetector> sdext::presenter::PresenterTextParagraph::mxScriptTypeDetector
private

Definition at line 182 of file PresenterTextView.hxx.

Referenced by Format(), and GetTextDirection().


The documentation for this class was generated from the following files: