LibreOffice Module vcl (master)  1
Public Member Functions | Private Member Functions | Private Attributes | List of all members
TextDoc Class Reference

#include <textdoc.hxx>

Public Member Functions

 TextDoc ()
 
 ~TextDoc ()
 
void Clear ()
 
std::vector< std::unique_ptr< TextNode > > & GetNodes ()
 
const std::vector< std::unique_ptr< TextNode > > & GetNodes () const
 
void RemoveChars (const TextPaM &rPaM, sal_Int32 nChars)
 
TextPaM InsertText (const TextPaM &rPaM, sal_Unicode c)
 
TextPaM InsertText (const TextPaM &rPaM, const OUString &rStr)
 
TextPaM InsertParaBreak (const TextPaM &rPaM)
 
TextPaM ConnectParagraphs (TextNode *pLeft, const TextNode *pRight)
 
sal_Int32 GetTextLen (const sal_Unicode *pSep, const TextSelection *pSel=nullptr) const
 
OUString GetText (const sal_Unicode *pSep) const
 
OUString GetText (sal_uInt32 nPara) const
 
void SetLeftMargin (sal_uInt16 n)
 
sal_uInt16 GetLeftMargin () const
 
bool IsValidPaM (const TextPaM &rPaM)
 

Private Member Functions

void DestroyTextNodes ()
 

Private Attributes

std::vector< std::unique_ptr< TextNode > > maTextNodes
 
sal_uInt16 mnLeftMargin
 

Detailed Description

Definition at line 94 of file textdoc.hxx.

Constructor & Destructor Documentation

TextDoc::TextDoc ( )

Definition at line 380 of file textdoc.cxx.

TextDoc::~TextDoc ( )

Definition at line 385 of file textdoc.cxx.

References DestroyTextNodes().

Member Function Documentation

void TextDoc::Clear ( )

Definition at line 390 of file textdoc.cxx.

References DestroyTextNodes().

TextPaM TextDoc::ConnectParagraphs ( TextNode pLeft,
const TextNode pRight 
)

Definition at line 497 of file textdoc.cxx.

References TextNode::Append(), TextNode::GetText(), and maTextNodes.

void TextDoc::DestroyTextNodes ( )
private

Definition at line 395 of file textdoc.cxx.

References maTextNodes.

Referenced by Clear(), and ~TextDoc().

sal_uInt16 TextDoc::GetLeftMargin ( ) const
inline

Definition at line 122 of file textdoc.hxx.

References mnLeftMargin.

std::vector<std::unique_ptr<TextNode> >& TextDoc::GetNodes ( )
inline

Definition at line 107 of file textdoc.hxx.

References maTextNodes.

Referenced by TextUndoDelPara::Redo().

const std::vector<std::unique_ptr<TextNode> >& TextDoc::GetNodes ( ) const
inline

Definition at line 108 of file textdoc.hxx.

References maTextNodes.

OUString TextDoc::GetText ( const sal_Unicode pSep) const

Definition at line 400 of file textdoc.cxx.

References TextNode::GetText(), and maTextNodes.

OUString TextDoc::GetText ( sal_uInt32  nPara) const

Definition at line 417 of file textdoc.cxx.

References TextNode::GetText(), and maTextNodes.

sal_Int32 TextDoc::GetTextLen ( const sal_Unicode pSep,
const TextSelection pSel = nullptr 
) const
TextPaM TextDoc::InsertParaBreak ( const TextPaM rPaM)
TextPaM TextDoc::InsertText ( const TextPaM rPaM,
sal_Unicode  c 
)
TextPaM TextDoc::InsertText ( const TextPaM rPaM,
const OUString &  rStr 
)

Definition at line 473 of file textdoc.cxx.

References TextPaM::GetIndex(), TextPaM::GetPara(), maTextNodes, and SAL_WARN_IF.

bool TextDoc::IsValidPaM ( const TextPaM rPaM)

Definition at line 519 of file textdoc.cxx.

References TextPaM::GetIndex(), TextPaM::GetPara(), TextNode::GetText(), and maTextNodes.

void TextDoc::RemoveChars ( const TextPaM rPaM,
sal_Int32  nChars 
)
void TextDoc::SetLeftMargin ( sal_uInt16  n)
inline

Definition at line 121 of file textdoc.hxx.

Member Data Documentation

std::vector<std::unique_ptr<TextNode> > TextDoc::maTextNodes
private
sal_uInt16 TextDoc::mnLeftMargin
private

Definition at line 97 of file textdoc.hxx.

Referenced by GetLeftMargin().


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