Public Member Functions | Protected Member Functions | Private Types | Private Attributes

Text_Listener Class Reference

#include <ie_exp_Text.h>

Inheritance diagram for Text_Listener:
PL_Listener ISCII_Listener

List of all members.

Public Member Functions

 Text_Listener (PD_Document *pDocument, IE_Exp_Text *pie, bool bToClipboard=false, const char *szEncoding=0, bool bIs16Bit=false, bool m_bUnicode=false, bool bUseBOM=false, bool bBigEndian=false)
virtual ~Text_Listener ()
virtual bool populate (fl_ContainerLayout *sfh, const PX_ChangeRecord *pcr)
virtual bool populateStrux (pf_Frag_Strux *sdh, const PX_ChangeRecord *pcr, fl_ContainerLayout **psfh)
virtual bool change (fl_ContainerLayout *sfh, const PX_ChangeRecord *pcr)
virtual bool insertStrux (fl_ContainerLayout *sfh, const PX_ChangeRecord *pcr, pf_Frag_Strux *sdh, PL_ListenerId lid, void(*pfnBindHandles)(pf_Frag_Strux *sdhNew, PL_ListenerId lid, fl_ContainerLayout *sfhNew))
virtual bool signal (UT_uint32 iSignal)

Protected Member Functions

int _wctomb (char *pC, int &length, UT_UCS4Char wc)
void _genBOM (void)
void _genLineBreak (void)
virtual void _outputData (const UT_UCSChar *p, UT_uint32 length)
void _closeBlock (void)
void _handleDirMarker (PT_AttrPropIndex apiSpan)

Private Types

enum  _dirOverride { DO_LTR, DO_RTL, DO_UNSET }

Private Attributes

UT_Wctomb m_wctomb
char m_mbBOM [MY_MB_LEN_MAX]
int m_iBOMLen
char m_mbLineBreak [MY_MB_LEN_MAX *2]
int m_iLineBreakLen
bool m_bInBlock
bool m_bFirstWrite
const char * m_szEncoding
bool m_bIs16Bit
bool m_bBigEndian
bool m_bUnicode
bool m_bUseBOM
bool m_bBreakExtra
_dirOverride m_eDirOverride
_dirOverride m_eDirMarkerPending
_dirOverride m_eSectionDir
_dirOverride m_eDocDir

Member Enumeration Documentation


Constructor & Destructor Documentation

Text_Listener::Text_Listener ( PD_Document pDocument,
IE_Exp_Text pie,
bool  bToClipboard = false,
const char *  szEncoding = 0,
bool  bIs16Bit = false,
bool  m_bUnicode = false,
bool  bUseBOM = false,
bool  bBigEndian = false 
Text_Listener::~Text_Listener (  )  [virtual]

Member Function Documentation

void Text_Listener::_closeBlock ( void   )  [protected]
void Text_Listener::_genBOM ( void   )  [protected]

Generate correct BOM

Makes a Byte Order Mark correct for the encoding.

References m_bBigEndian, m_bIs16Bit, m_iBOMLen, and m_mbBOM.

Referenced by _outputData().

void Text_Listener::_genLineBreak ( void   )  [protected]

Generate correct line break characters

Makes a line break correct for the encoding and platform.

References _wctomb(), m_iLineBreakLen, m_mbLineBreak, UT_ASSERT_HARMLESS, and UT_ASSERT_NOT_REACHED.

Referenced by _outputData().

void Text_Listener::_outputData ( const UT_UCSChar data,
UT_uint32  length 
) [protected, virtual]
int Text_Listener::_wctomb ( char *  pC,
int &  length,
UT_UCS4Char  wc 
) [inline, protected]

Reimplemented in ISCII_Listener.

Referenced by _genLineBreak(), and _outputData().

bool Text_Listener::change ( fl_ContainerLayout sfh,
const PX_ChangeRecord pcr 
) [virtual]

Implements PL_Listener.


virtual bool Text_Listener::insertStrux ( fl_ContainerLayout sfh,
const PX_ChangeRecord pcr,
pf_Frag_Strux sdh,
PL_ListenerId  lid,
void(*)(pf_Frag_Strux *sdhNew, PL_ListenerId lid, fl_ContainerLayout *sfhNew)  pfnBindHandles 
) [virtual]

Implements PL_Listener.

bool Text_Listener::signal ( UT_uint32  iSignal  )  [virtual]

Implements PL_Listener.


Member Data Documentation

Referenced by _genBOM().

Referenced by _closeBlock(), and populateStrux().

bool Text_Listener::m_bInBlock [private]

Referenced by _closeBlock(), and populateStrux().

bool Text_Listener::m_bIs16Bit [private]

Referenced by _genBOM(), and _outputData().

bool Text_Listener::m_bUnicode [private]

Referenced by populateStrux().

bool Text_Listener::m_bUseBOM [private]

Referenced by _outputData().

int Text_Listener::m_iBOMLen [private]

Referenced by _genBOM(), and _outputData().

char Text_Listener::m_mbBOM[MY_MB_LEN_MAX] [private]

Referenced by _genBOM(), and _outputData().

char Text_Listener::m_mbLineBreak[MY_MB_LEN_MAX *2] [private]
const char* Text_Listener::m_szEncoding [private]

Referenced by _outputData().

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