Public Member Functions | Private Member Functions | Private Attributes

fl_DocListener Class Reference

#include <fl_DocListener.h>

Inheritance diagram for fl_DocListener:
PL_Listener

List of all members.

Public Member Functions

 fl_DocListener (PD_Document *doc, FL_DocLayout *pLayout)
virtual ~fl_DocListener ()
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 void deferNotifications (void)
virtual void processDeferredNotifications (void)
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))
void setHoldTableLayout (bool bHold)
bool holdTableLayout (void)
virtual bool signal (UT_uint32 iSignal)
virtual PLListenerType getType () const
const FL_DocLayoutgetLayout () const

Private Member Functions

fl_ContainerLayoutpopContainerLayout (void)
void pushContainerLayout (fl_ContainerLayout *pCL)
fl_ContainerLayoutgetTopContainerLayout (void)

Private Attributes

PD_Documentm_pDoc
 Document which is client of this DocListener.
FL_DocLayoutm_pLayout
 The Layout notified by this DocListener.
bool m_bScreen
 Set when the document is drawn on screen.
bool m_bHoldTableLayout
UT_uint32 m_iGlobCounter
 Counter used to keep track of when to update the Layout.
fl_SectionLayoutm_pCurrentSL
 SectionLayout currently being constructed (multi-step change related?!?).
UT_Stack m_sLastContainerLayout
bool m_bFootnoteInProgress
bool m_bEndFootnoteProcessedInBlock
AV_ChangeMask m_chgMaskCached
bool m_bCacheChanges
AP_StatusBarm_pStatusBar
UT_sint32 m_iFilled

Detailed Description

The fl_DocListener class handles notifications from a PD_Document to its associated FL_DocLayout.


Constructor & Destructor Documentation

fl_DocListener::~fl_DocListener (  )  [virtual]

Destruct DocListener

References UT_Stack::getDepth(), m_sLastContainerLayout, and UT_ASSERT.


Member Function Documentation

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

Change a strux or span.

Implements PL_Listener.

References FV_View::_setPoint(), FV_View::addCaret(), FL_DocLayout::addHdrFtrSection(), AV_CHG_FMTBLOCK, AV_CHG_HDRFTR, AV_CHG_NONE, fl_SectionLayout::bl_doclistener_changeFmtMark(), fl_HdrFtrSectionLayout::bl_doclistener_changeFmtMark(), fl_SectionLayout::bl_doclistener_changeObject(), fl_HdrFtrSectionLayout::bl_doclistener_changeObject(), fl_SectionLayout::bl_doclistener_changeSpan(), fl_HdrFtrSectionLayout::bl_doclistener_changeSpan(), fl_SectionLayout::bl_doclistener_changeStrux(), fl_HdrFtrSectionLayout::bl_doclistener_changeStrux(), fl_SectionLayout::bl_doclistener_deleteFmtMark(), fl_HdrFtrSectionLayout::bl_doclistener_deleteFmtMark(), fl_SectionLayout::bl_doclistener_deleteObject(), fl_HdrFtrSectionLayout::bl_doclistener_deleteObject(), fl_SectionLayout::bl_doclistener_deleteSpan(), fl_HdrFtrSectionLayout::bl_doclistener_deleteSpan(), fl_SectionLayout::bl_doclistener_deleteStrux(), fl_HdrFtrSectionLayout::bl_doclistener_deleteStrux(), fl_SectionLayout::bl_doclistener_insertFmtMark(), fl_HdrFtrSectionLayout::bl_doclistener_insertFmtMark(), fl_SectionLayout::bl_doclistener_insertObject(), fl_HdrFtrSectionLayout::bl_doclistener_insertObject(), fl_SectionLayout::bl_doclistener_insertSpan(), fl_HdrFtrSectionLayout::bl_doclistener_insertSpan(), FL_DocLayout::changeDocSections(), fl_HdrFtrSectionLayout::changeIntoHdrFtrSection(), fl_TOCLayout::doclistener_changeStrux(), fl_FrameLayout::doclistener_changeStrux(), fl_CellLayout::doclistener_changeStrux(), fl_TableLayout::doclistener_changeStrux(), fl_DocSectionLayout::doclistener_changeStrux(), fl_BlockLayout::findRunAtOffset(), FL_DocLayout::findSectionForHdrFtr(), FL_HDRFTR_NONE, fl_HdrFtrSectionLayout::format(), gchar, PP_AttrProp::getAttribute(), PD_Document::getAttrProp(), PX_ChangeRecord_Object::getBlockOffset(), fl_ContainerLayout::getContainerType(), FL_DocLayout::getDocument(), PX_ChangeRecord_Glob::getFlags(), fl_ContainerLayout::getHdrFtrSectionLayout(), PX_ChangeRecord::getIndexAP(), getLayout(), fp_BookmarkRun::getName(), PX_ChangeRecord_Object::getObjectType(), PX_ChangeRecord::getPosition(), PP_AttrProp::getProperty(), fl_ContainerLayout::getSectionLayout(), fl_BlockLayout::getSectionLayout(), fl_Layout::getStruxDocHandle(), PX_ChangeRecord_Strux::getStruxType(), fp_Run::getType(), fl_SectionLayout::getType(), fl_Layout::getType(), PX_ChangeRecord::getType(), fl_BlockLayout::getView(), FL_DocLayout::getView(), AV_View::incTick(), FV_View::isActive(), fl_ContainerLayout::isCollapsed(), PX_ChangeRecord_StruxChange::isRevisionDelete(), fp_BookmarkRun::isStartOfBookmark(), m_bCacheChanges, m_chgMaskCached, m_iGlobCounter, m_pDoc, m_pLayout, PD_Document::miniDump(), FV_View::notifyListeners(), PT_DOCPROP_ATTRIBUTE_NAME, PTX_Block, PTX_EndAnnotation, PTX_EndCell, PTX_EndEndnote, PTX_EndFootnote, PTX_EndFrame, PTX_EndTable, PTX_EndTOC, PTX_Section, PTX_SectionAnnotation, PTX_SectionCell, PTX_SectionEndnote, PTX_SectionFootnote, PTX_SectionFrame, PTX_SectionHdrFtr, PTX_SectionTable, PTX_SectionTOC, PX_ChangeRecord_Glob::PXF_MultiStepEnd, PX_ChangeRecord_Glob::PXF_MultiStepStart, PX_ChangeRecord_Glob::PXF_Null, PX_ChangeRecord_Glob::PXF_UserAtomicEnd, PX_ChangeRecord_Glob::PXF_UserAtomicStart, PX_ChangeRecord::PXT_ChangeDocProp, PX_ChangeRecord::PXT_ChangeFmtMark, PX_ChangeRecord::PXT_ChangeObject, PX_ChangeRecord::PXT_ChangePoint, PX_ChangeRecord::PXT_ChangeSpan, PX_ChangeRecord::PXT_ChangeStrux, PX_ChangeRecord::PXT_CreateDataItem, PX_ChangeRecord::PXT_DeleteFmtMark, PX_ChangeRecord::PXT_DeleteObject, PX_ChangeRecord::PXT_DeleteSpan, PX_ChangeRecord::PXT_DeleteStrux, PX_ChangeRecord::PXT_GlobMarker, PX_ChangeRecord::PXT_InsertFmtMark, PX_ChangeRecord::PXT_InsertObject, PX_ChangeRecord::PXT_InsertSpan, PX_ChangeRecord::PXT_InsertStrux, PX_ChangeRecord::PXT_ListUpdate, PX_ChangeRecord::PXT_RemoveList, PX_ChangeRecord::PXT_StopList, PX_ChangeRecord::PXT_UpdateField, PX_ChangeRecord::PXT_UpdateLayout, FL_DocLayout::refreshRunProperties(), s_convertToHdrFtrType(), fl_Layout::setAttrPropIndex(), fl_HdrFtrSectionLayout::setDocSectionLayout(), FL_DocLayout::setDocViewPageSize(), fl_HdrFtrSectionLayout::setHdrFtr(), fl_DocSectionLayout::setHdrFtr(), FL_DocLayout::setNeedsRedraw(), FL_DocLayout::updateLayout(), FV_View::updateScreen(), FL_DocLayout::updateTOCsOnBookmarkChange(), UT_ASSERT, UT_ASSERT_HARMLESS, UT_DEBUGMSG, UT_return_val_if_fail, UT_SHOULD_NOT_HAPPEN, UT_WARNINGMSG, and xxx_UT_DEBUGMSG.

void fl_DocListener::deferNotifications ( void   )  [virtual]

Reimplemented from PL_Listener.

References m_bCacheChanges, and m_chgMaskCached.

const FL_DocLayout* fl_DocListener::getLayout (  )  const [inline]
fl_ContainerLayout * fl_DocListener::getTopContainerLayout ( void   )  [private]

View the topmost containerLayout on the stack.

References m_sLastContainerLayout, and UT_Stack::viewTop().

Referenced by populateStrux().

virtual PLListenerType fl_DocListener::getType ( void   )  const [inline, virtual]

Reimplemented from PL_Listener.

bool fl_DocListener::holdTableLayout ( void   )  [inline]

Referenced by populateStrux().

bool fl_DocListener::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.

References fl_TableLayout::bl_doclistener_insertBlock(), fl_HdrFtrSectionLayout::bl_doclistener_insertBlock(), fl_SectionLayout::bl_doclistener_insertBlock(), fl_TableLayout::bl_doclistener_insertCell(), fl_CellLayout::bl_doclistener_insertEndCell(), fl_EmbedLayout::bl_doclistener_insertEndEmbed(), fl_FrameLayout::bl_doclistener_insertEndFrame(), fl_TOCLayout::bl_doclistener_insertEndTOC(), fl_SectionLayout::bl_doclistener_insertFrame(), fl_SectionLayout::bl_doclistener_insertSection(), fl_TableLayout::bl_doclistener_insertTable(), fl_SectionLayout::bl_doclistener_insertTable(), FL_SECTION_ANNOTATION, FL_SECTION_DOC, FL_SECTION_ENDNOTE, FL_SECTION_FOOTNOTE, FL_SECTION_FRAME, FL_SECTION_HDRFTR, FL_SECTION_TABLE, FL_SECTION_TOC, fl_ContainerLayout::getContainerType(), fl_ContainerLayout::getHdrFtrSectionLayout(), PX_ChangeRecord::getPosition(), fl_ContainerLayout::getPrev(), fl_ContainerLayout::getSectionLayout(), fl_Layout::getStruxDocHandle(), fl_SectionLayout::getType(), fl_Layout::getType(), PX_ChangeRecord::getType(), m_pCurrentSL, m_pDoc, PD_Document::miniDump(), fl_ContainerLayout::myContainingLayout(), PTX_Block, PTX_EndAnnotation, PTX_EndCell, PTX_EndEndnote, PTX_EndFootnote, PTX_EndFrame, PTX_EndTable, PTX_EndTOC, PTX_Section, PTX_SectionAnnotation, PTX_SectionCell, PTX_SectionEndnote, PTX_SectionFootnote, PTX_SectionFrame, PTX_SectionHdrFtr, PTX_SectionTable, PTX_SectionTOC, UT_ASSERT, UT_DEBUGMSG, UT_return_val_if_fail, UT_SHOULD_NOT_HAPPEN, and xxx_UT_DEBUGMSG.

fl_ContainerLayout * fl_DocListener::popContainerLayout ( void   )  [private]

Pop the most recent ContainerLayout off the top of the stack.

References m_sLastContainerLayout, and UT_Stack::pop().

Referenced by populateStrux().

bool fl_DocListener::populateStrux ( pf_Frag_Strux sdh,
const PX_ChangeRecord pcr,
fl_ContainerLayout **  psfh 
) [virtual]

Implements PL_Listener.

References FL_DocLayout::addHdrFtrSection(), FL_DocLayout::addSection(), fl_ContainerLayout::append(), fl_TableLayout::attachCell(), FL_DocLayout::bgcrGrammar, FL_DocLayout::bgcrSpelling, countStrux, FL_DocLayout::findSectionForHdrFtr(), FL_HDRFTR_NONE, FL_SECTION_HDRFTR, fl_TableLayout::format(), fl_ContainerLayout::format(), fl_DocSectionLayout::format(), FV_DOCPOS_BOD, gchar, XAP_App::getApp(), PP_AttrProp::getAttribute(), PD_Document::getAttrProp(), fl_ContainerLayout::getContainerType(), fl_BlockLayout::getDocSectionLayout(), fl_ContainerLayout::getDocSectionLayout(), FL_DocLayout::getDocSize(), fl_ContainerLayout::getFirstLayout(), FL_DocLayout::getFirstSection(), fl_ContainerLayout::getHdrFtrLayout(), PX_ChangeRecord::getIndexAP(), fl_ContainerLayout::getLastContainer(), XAP_App::getLastFocussedFrame(), FL_DocLayout::getLastSection(), fl_ContainerLayout::getNext(), FV_View::getPoint(), fl_ContainerLayout::getPrev(), fl_ContainerLayout::getSectionLayout(), XAP_App::getStringSet(), getTopContainerLayout(), fl_SectionLayout::getType(), PX_ChangeRecord::getType(), XAP_StringSet::getValue(), FL_DocLayout::getView(), holdTableLayout(), FL_DocLayout::isLayoutFilling(), m_bEndFootnoteProcessedInBlock, m_bFootnoteInProgress, m_bScreen, m_iFilled, m_iGlobCounter, m_pCurrentSL, m_pDoc, m_pLayout, m_pStatusBar, PD_Document::miniDump(), FV_View::moveInsPtTo(), XAP_Frame::nullUpdate(), popContainerLayout(), PTX_Block, PTX_EndAnnotation, PTX_EndCell, PTX_EndEndnote, PTX_EndFootnote, PTX_EndFrame, PTX_EndTable, PTX_EndTOC, PTX_Section, PTX_SectionAnnotation, PTX_SectionCell, PTX_SectionEndnote, PTX_SectionFootnote, PTX_SectionFrame, PTX_SectionHdrFtr, PTX_SectionTable, PTX_SectionTOC, pushContainerLayout(), s_convertToHdrFtrType(), fl_TableLayout::setDirty(), PD_Document::setDontImmediatelyLayout(), fl_Layout::setEndStruxDocHandle(), fl_TableLayout::setEndTableIn(), fl_EmbedLayout::setFootnoteEndIn(), fl_DocSectionLayout::setHdrFtr(), FL_DocLayout::setPercentFilled(), AP_StatusBar::setStatusMessage(), AP_StatusBar::setStatusProgressValue(), fl_BlockLayout::updateEnclosingBlockIfNeeded(), FL_DocLayout::updateLayout(), UT_ASSERT, UT_DEBUGMSG, UT_return_val_if_fail, UT_SHOULD_NOT_HAPPEN, UT_UTF8String_sprintf(), and xxx_UT_DEBUGMSG.

void fl_DocListener::processDeferredNotifications ( void   )  [virtual]
void fl_DocListener::pushContainerLayout ( fl_ContainerLayout pCL  )  [private]

Push the given ContainerLayout onto the top of the stack.

References m_sLastContainerLayout, and UT_Stack::push().

Referenced by populateStrux().

void fl_DocListener::setHoldTableLayout ( bool  bHold  )  [inline]

Member Data Documentation

bool fl_DocListener::m_bScreen [private]

Set when the document is drawn on screen.

Referenced by fl_DocListener(), and populateStrux().

Counter used to keep track of when to update the Layout.

In case of multi-step changes, updating is suspended.

Referenced by change(), fl_DocListener(), populate(), and populateStrux().

SectionLayout currently being constructed (multi-step change related?!?).

Referenced by fl_DocListener(), insertStrux(), and populateStrux().

Document which is client of this DocListener.

Referenced by change(), fl_DocListener(), insertStrux(), populate(), and populateStrux().

The Layout notified by this DocListener.

Referenced by change(), fl_DocListener(), populate(), populateStrux(), and signal().


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