FL_DocLayout Class Reference

#include <fl_DocLayout.h>

List of all members.

Public Types

enum  backgroundCheckReason {
  bgcrNone = 0, bgcrDebugFlash = (1 << 0), bgcrSpelling = (1 << 1), bgcrSmartQuotes = (1 << 2),
  bgcrGrammar = (1 << 3)
}

Public Member Functions

 FL_DocLayout (PD_Document *doc, GR_Graphics *pG)
 ~FL_DocLayout ()
void fillLayouts (void)
void setView (FV_View *)
FV_ViewgetView (void) const
GR_GraphicsgetGraphics (void) const
void setGraphics (GR_Graphics *pG)
UT_uint32 getGraphicTick (void) const
void incrementGraphicTick (void)
PD_DocumentgetDocument (void) const
fl_BlockLayoutgetPendingBlockForSmartQuote (void) const
UT_uint32 getOffsetForSmartQuote (void) const
void setPendingSmartQuote (fl_BlockLayout *block, UT_uint32 offset)
void considerSmartQuoteCandidateAt (fl_BlockLayout *block, UT_uint32 offset)
void considerPendingSmartQuoteCandidate ()
void notifyBlockIsBeingDeleted (fl_BlockLayout *pBlock)
void setSkipUpdates (UT_uint32 numSkips)
UT_uint32 getSkipUpdates (void)
UT_sint32 getHeight ()
UT_sint32 getWidth ()
void refreshRunProperties (void)
const GR_FontfindFont (const PP_AttrProp *pSpanAP, const PP_AttrProp *pBlockAP, const PP_AttrProp *pSectionAP, bool isField=false)
const GR_FontfindFont (const PP_AttrProp *pSpanAP, const PP_AttrProp *pBlockAP, const PP_AttrProp *pSectionAP, GR_Graphics *pG, bool isField=false)
void changeDocSections (const PX_ChangeRecord_StruxChange *pcrx, fl_DocSectionLayout *pDSL)
fp_PageaddNewPage (fl_DocSectionLayout *pOwner, bool bNoUpdate=false)
fp_PagegetFirstPage ()
fp_PagegetLastPage ()
fp_PagegetNthPage (int n)
UT_uint32 countPages ()
UT_sint32 findPage (fp_Page *pPage)
void setFramePageNumbers (UT_sint32 iStartPage)
void relocateFrame (fl_FrameLayout *pFrame)
UT_sint32 getPercentFilled (void)
void setPercentFilled (UT_sint32 iFill)
void setLayoutIsFilling (bool bisFill)
bool isLayoutFilling (void) const
fl_BlockLayoutfindBlockAtPosition (PT_DocPosition pos) const
fl_BlockLayoutfindBlockAtPositionReverse (PT_DocPosition pos)
void deletePage (fp_Page *pPage, bool bDontNotify)
void formatAll ()
void updateLayout ()
void updateOnViewModeChange ()
void rebuildFromHere (fl_DocSectionLayout *pDSL)
void updateColor ()
void addSection (fl_DocSectionLayout *)
void removeSection (fl_DocSectionLayout *)
void insertSectionAfter (fl_DocSectionLayout *pAfter, fl_DocSectionLayout *pNewSL)
void addHdrFtrSection (fl_SectionLayout *pHdrFtrSL)
void removeHdrFtrSection (fl_SectionLayout *pHdrFtrSL)
fl_DocSectionLayoutgetFirstSection (void) const
fl_DocSectionLayoutgetLastSection (void) const
fl_DocSectionLayoutfindSectionForHdrFtr (const char *pszHdrFtrID) const
void deleteEmptyColumnsAndPages (void)
void deleteEmptyPages (bool bDontNotify=false)
GR_EmbedManagergetEmbedManager (const char *szEmbedType)
UT_uint32 countFootnotes (void)
void addFootnote (fl_FootnoteLayout *)
void removeFootnote (fl_FootnoteLayout *)
fl_FootnoteLayoutgetNthFootnote (UT_sint32 i)
UT_sint32 getFootnoteVal (UT_uint32 footpid)
fl_FootnoteLayoutfindFootnoteLayout (UT_uint32 footpid)
FootnoteType getFootnoteType (void) const
void getStringFromFootnoteVal (UT_String &sVal, UT_sint32 iVal, FootnoteType iFootType)
UT_sint32 getInitialFootVal (void) const
bool getRestartFootOnSection (void) const
bool getRestartFootOnPage (void) const
FootnoteType FootnoteTypeFromString (const gchar *pszStr)
void insertEndnoteContainer (fp_EndnoteContainer *pECon)
void removeEndnoteContainer (fp_EndnoteContainer *pECon)
fl_DocSectionLayoutgetDocSecForEndnote (fp_EndnoteContainer *pECon)
UT_uint32 countEndnotes (void)
void addEndnote (fl_EndnoteLayout *)
void removeEndnote (fl_EndnoteLayout *)
fl_EndnoteLayoutgetNthEndnote (UT_sint32 i)
UT_sint32 getEndnoteVal (UT_uint32 endpid)
fl_EndnoteLayoutfindEndnoteLayout (UT_uint32 endpid)
FootnoteType getEndnoteType (void) const
UT_sint32 getInitialEndVal (void) const
bool getRestartEndOnSection (void) const
bool getPlaceEndAtDocEnd (void) const
bool getPlaceEndAtSecEnd (void) const
UT_uint32 countAnnotations (void)
void addAnnotation (fl_AnnotationLayout *pAL)
void removeAnnotation (fl_AnnotationLayout *pAL)
fl_AnnotationLayoutgetNthAnnotation (UT_sint32 i)
UT_sint32 getAnnotationVal (UT_uint32 footpid)
fl_AnnotationLayoutfindAnnotationLayout (UT_uint32 footpid)
bool displayAnnotations (void)
void setDisplayAnnotations (bool bDisplayAnnotations)
bool collapseAnnotations (void)
UT_sint32 getNumTOCs (void)
fl_TOCLayoutgetNthTOC (UT_sint32 i)
bool addOrRemoveBlockFromTOC (fl_BlockLayout *pBlock)
bool removeBlockFromTOC (fl_BlockLayout *pBlock)
bool isBlockInTOC (fl_BlockLayout *pBlock)
bool getMatchingBlocksFromTOCs (fl_BlockLayout *pBlock, UT_GenericVector< fl_BlockLayout * > *pVecBlock)
bool addTOC (fl_TOCLayout *pTOC)
bool removeTOC (fl_TOCLayout *pTOC)
bool fillTOC (fl_TOCLayout *pTOC)
void recalculateTOCFields (void)
bool updateTOCsOnBookmarkChange (const gchar *pBookmark)
bool getSmartQuotes (void) const
void addBackgroundCheckReason (UT_uint32 reason)
void removeBackgroundCheckReason (UT_uint32 reason)
bool hasBackgroundCheckReason (UT_uint32 reason) const
UT_uint32 getBackgroundCheckReasons () const
void triggerPendingBlock (fl_BlockLayout *pBL)
fl_AutoNumgetListByID (UT_uint32 id) const
fl_AutoNumgetNthList (UT_uint32 i) const
UT_uint32 getListsCount (void) const
void addList (fl_AutoNum *pAutoNum)
bool isLayoutDeleting (void) const
UT_uint32 getRedrawCount ()
void updatePropsNoRebuild (void)
void updatePropsRebuild (void)
PT_DocPosition getDocSize (void)
UT_uint32 getLID (void) const
void notifyListeners (AV_ChangeMask mask)
void setQuickPrint (GR_Graphics *pGraphics)
bool isQuickPrint (void)
GR_EmbedManagergetQuickPrintEmbedManager (const char *szEmbedType)
bool setDocViewPageSize (const PP_AttrProp *pAP)
 FL_DocLayout ()
fl_BlockLayoutspellQueueHead (void) const
void setSpellQueueHead (fl_BlockLayout *h)
void setSpellQueueTail (fl_BlockLayout *t)
 FL_DocLayout ()
fl_BlockLayoutspellQueueHead (void) const
void setSpellQueueHead (fl_BlockLayout *h)
void setSpellQueueTail (fl_BlockLayout *t)

Public Attributes

fp_PageSize m_docViewPageSize
fl_BlockLayoutm_toSpellCheckHead
fl_BlockLayoutm_toSpellCheckTail
fl_BlockLayoutm_toSpellCheckHead
fl_BlockLayoutm_toSpellCheckTail

Protected Member Functions

void _toggleAutoSmartQuotes (bool bSQ)

Static Protected Member Functions

static void _backgroundCheck (UT_Worker *pTimer)
static void _prefsListener (class XAP_App *, class XAP_Prefs *, UT_StringPtrMap *, void *)
static void _redrawUpdate (UT_Worker *pTimer)

Private Member Functions

void _lookupProperties (void)

Private Attributes

GR_Graphicsm_pG
PD_Documentm_pDoc
FV_Viewm_pView
fl_DocListenerm_pDocListener
PL_ListenerId m_lid
UT_GenericVector< fp_Page * > m_vecPages
fl_DocSectionLayoutm_pFirstSection
fl_DocSectionLayoutm_pLastSection
fl_BlockLayoutm_toSpellCheckHead
fl_BlockLayoutm_toSpellCheckTail
fl_BlockLayoutm_pPendingBlockForSpell
fl_PartOfBlockm_pPendingWordForSpell
bool m_bSpellCheckCaps
bool m_bSpellCheckNumbers
bool m_bSpellCheckInternet
bool m_bAutoSpellCheck
UT_uint32 m_uDocBackgroundCheckReasons
bool m_bStopSpellChecking
bool m_bImSpellCheckingNow
fl_BlockLayoutm_pPendingBlockForSmartQuote
UT_uint32 m_uOffsetForSmartQuote
char m_szCurrentTransparentColor [10]
UT_Workerm_pBackgroundCheckTimer
XAP_Prefsm_pPrefs
UT_Timerm_pRedrawUpdateTimer
UT_uint32 m_iSkipUpdates
bool m_bDeletingLayout
bool m_bisLayoutFilling
UT_uint32 m_iRedrawCount
UT_GenericVector
< fl_FootnoteLayout * > 
m_vecFootnotes
UT_GenericVector
< fl_AnnotationLayout * > 
m_vecAnnotations
UT_GenericVector
< fl_EndnoteLayout * > 
m_vecEndnotes
FootnoteType m_FootnoteType
UT_sint32 m_iFootnoteVal
bool m_bRestartFootSection
bool m_bRestartFootPage
UT_sint32 m_iEndnoteVal
FootnoteType m_EndnoteType
bool m_bRestartEndSection
bool m_bPlaceAtDocEnd
bool m_bPlaceAtSecEnd
UT_uint32 m_iGraphicTick
UT_GenericVector< fl_TOCLayout * > m_vecTOC
PT_DocPosition m_iDocSize
UT_sint32 m_iFilled
bool m_bSpellCheckInProgress
UT_GenericVector
< GR_EmbedManager * > 
m_vecEmbedManager
bool m_bAutoGrammarCheck
fl_BlockLayoutm_PendingBlockForGrammar
UT_sint32 m_iGrammarCount
bool m_bFinishedInitialCheck
PT_DocPosition m_iPrevPos
UT_GenericVector
< GR_EmbedManager * > 
m_vecQuickPrintEmbedManager
GR_Graphicsm_pQuickPrintGraphics
bool m_bIsQuickPrint
bool m_bDisplayAnnotations

Friends

class fl_DocListener
class fl_BlockLayout


Member Enumeration Documentation

Enumerator:
bgcrNone 
bgcrDebugFlash 
bgcrSpelling 
bgcrSmartQuotes 
bgcrGrammar 


Constructor & Destructor Documentation

FL_DocLayout::FL_DocLayout ( PD_Document doc,
GR_Graphics pG 
)

FL_DocLayout::~FL_DocLayout (  ) 

FL_DocLayout::FL_DocLayout (  )  [inline]

FL_DocLayout::FL_DocLayout (  )  [inline]


Member Function Documentation

void FL_DocLayout::fillLayouts ( void   ) 

This Method fills the layout structures from the PieceTable.

References _lookupProperties(), PD_Document::addListener(), FV_View::clearCursorWait(), fl_DocSectionLayout::completeBreakSection(), GR_Graphics::DGP_PAPER, FL_CONTAINER_BLOCK, FL_CONTAINER_DOCSECTION, fl_DocListener, fl_ContainerLayout::format(), formatAll(), FV_DOCPOS_BOD, PD_Document::getBounds(), fl_ContainerLayout::getContainerType(), getDocument(), getFirstPage(), getFirstSection(), getGraphics(), fl_ContainerLayout::getLastContainer(), fl_ContainerLayout::getLastLayout(), getLastSection(), fp_Page::getNext(), fl_ContainerLayout::getNext(), getNthTOC(), getNumTOCs(), fp_Line::getPage(), AV_View::getParentData(), fl_ContainerLayout::getPrevBlockInDocument(), fl_TOCLayout::getSectionLayout(), m_bFinishedInitialCheck, PD_Document::m_docPageSize, m_docViewPageSize, m_iDocSize, m_iGrammarCount, m_iPrevPos, m_lid, m_pDoc, m_pDocListener, m_pView, FV_View::moveInsPtTo(), GR_Graphics::queryProperties(), PD_Document::setDontImmediatelyLayout(), setFramePageNumbers(), fl_DocListener::setHoldTableLayout(), AV_View::setLayoutIsFilling(), setLayoutIsFilling(), FV_View::setPoint(), XAP_Frame::setYScrollRange(), updateLayout(), FV_View::updateLayout(), FV_View::updateScreen(), UT_ASSERT, UT_ASSERT_HARMLESS, UT_return_if_fail, UT_SHOULD_NOT_HAPPEN, and fl_TOCLayout::verifyBookmarkAssumptions().

Referenced by FakeAccountHandler::_loadDocument(), AP_Frame::_replaceView(), IE_Exp_S5::_writeDocument(), IE_Exp_PDF::_writeDocument(), AP_Preview_Abi::AP_Preview_Abi(), FV_View::copyTextToClipboard(), Defun(), Defun1(), Print_MailMerge_Listener::fireUpdate(), AP_Convert::print(), AbiCommand::printFiles(), AP_Convert::printFirstPage(), AbiCommand::replaceDocument(), s_doPrint(), s_doPrintPreview(), s_pasteFile(), and IE_FieldUpdater::updateFields().

void FL_DocLayout::setView ( FV_View pView  ) 

FV_View* FL_DocLayout::getView ( void   )  const [inline]

Referenced by fp_Line::_createMapOfRuns(), fp_TextRun::_draw(), fp_CellContainer::_drawBoundaries(), fp_Column::_drawBoundaries(), fp_TableContainer::_drawBrokenBoundaries(), fp_ShadowContainer::_drawHdrFtrBoundaries(), fp_TextRun::_drawInvisibleSpaces(), fp_CellContainer::_getBrokenRect(), fl_DocSectionLayout::_HdrFtrChangeCallback(), fl_TableLayout::_lookupMarginProperties(), fl_FrameLayout::_lookupMarginProperties(), fl_TableLayout::_lookupProperties(), fl_DocSectionLayout::_lookupProperties(), fl_FrameLayout::_lookupProperties(), AP_Win32App::_pasteFormatFromClipboard(), _prefsListener(), _redrawUpdate(), fl_CellLayout::_updateCell(), fl_DocSectionLayout::bl_doclistener_insertAnnotation(), fl_TableLayout::bl_doclistener_insertBlock(), fl_SectionLayout::bl_doclistener_insertBlock(), fl_CellLayout::bl_doclistener_insertCell(), fl_TableLayout::bl_doclistener_insertCell(), fl_CellLayout::bl_doclistener_insertEndCell(), fl_EmbedLayout::bl_doclistener_insertEndEmbed(), fl_FrameLayout::bl_doclistener_insertEndFrame(), fl_TableLayout::bl_doclistener_insertEndTable(), fl_TOCLayout::bl_doclistener_insertEndTOC(), fl_DocSectionLayout::bl_doclistener_insertFootnote(), fl_SectionLayout::bl_doclistener_insertSection(), fl_TableLayout::bl_doclistener_insertTable(), fl_HdrFtrSectionLayout::bl_doclistener_insertTable(), fl_SectionLayout::bl_doclistener_insertTable(), fl_ContainerLayout::canContainPoint(), fl_DocListener::change(), fl_Squiggles::clear(), fp_ShadowContainer::clearScreen(), fl_HdrFtrSectionLayout::collapse(), fl_FrameLayout::collapse(), fl_DocSectionLayout::doclistener_deleteStrux(), fl_BlockLayout::doclistener_deleteStrux(), fp_ShadowContainer::draw(), fp_CellContainer::drawBroken(), fp_CellContainer::drawSelectedCell(), Drop(), fl_HdrFtrShadow::findBlockAtPosition(), findBlockAtPosition(), findBlockAtPositionReverse(), fl_DocSectionLayout::format(), fl_FrameLayout::format(), fl_EndnoteLayout::format(), PD_Document::getAllViews(), fl_ContainerLayout::getAP(), getHeight(), fp_CellContainer::getScreenPositions(), fl_ContainerLayout::getSpanAP(), fp_VerticalContainer::getView(), getWidth(), fl_FrameLayout::insertBlockAfter(), fl_CellLayout::isCellSelected(), fp_Container::isOnScreen(), fl_ContainerLayout::isOnScreen(), fp_ShadowContainer::layout(), fl_FrameLayout::miniFormat(), fl_ShadowListener::populate(), fl_ShadowListener::populateStrux(), fl_DocListener::populateStrux(), fl_DocListener::processDeferredNotifications(), fl_FrameLayout::recalculateFields(), fl_HdrFtrShadow::redrawUpdate(), AP_Dialog_Spell::runModal(), setDocViewPageSize(), fl_DocSectionLayout::setPaperColor(), fl_TOCLayout::setSelected(), fl_DocListener::signal(), updateColor(), fl_DocSectionLayout::updateDocSection(), fl_DocSectionLayout::updateLayout(), fl_FrameLayout::updateLayout(), fl_TableLayout::updateTable(), and fl_FrameLayout::~fl_FrameLayout().

GR_Graphics* FL_DocLayout::getGraphics ( void   )  const [inline]

void FL_DocLayout::setGraphics ( GR_Graphics pG  ) 

Change the graphics pointer for this layout.Needed for quick zoom.

References m_iGraphicTick, m_pG, and updatePropsRebuild().

UT_uint32 FL_DocLayout::getGraphicTick ( void   )  const [inline]

void FL_DocLayout::incrementGraphicTick ( void   )  [inline]

PD_Document* FL_DocLayout::getDocument ( void   )  const [inline]

fl_BlockLayout* FL_DocLayout::getPendingBlockForSmartQuote ( void   )  const [inline]

UT_uint32 FL_DocLayout::getOffsetForSmartQuote ( void   )  const [inline]

void FL_DocLayout::setPendingSmartQuote ( fl_BlockLayout block,
UT_uint32  offset 
)

void FL_DocLayout::considerSmartQuoteCandidateAt ( fl_BlockLayout block,
UT_uint32  offset 
)

void FL_DocLayout::considerPendingSmartQuoteCandidate (  )  [inline]

void FL_DocLayout::notifyBlockIsBeingDeleted ( fl_BlockLayout pBlock  ) 

void FL_DocLayout::setSkipUpdates ( UT_uint32  numSkips  )  [inline]

UT_uint32 FL_DocLayout::getSkipUpdates ( void   )  [inline]

Referenced by _redrawUpdate().

UT_sint32 FL_DocLayout::getHeight ( void   ) 

UT_sint32 FL_DocLayout::getWidth ( void   ) 

void FL_DocLayout::refreshRunProperties ( void   ) 

This method is used to reset the colorization such as what occurs when showAuthors state is changed.

References fl_SectionLayout::getFirstBlock(), getFirstSection(), fl_ContainerLayout::getNextBlockInDocument(), and fl_BlockLayout::refreshRunProperties().

Referenced by fl_DocListener::change(), and PD_Document::setShowAuthors().

const GR_Font * FL_DocLayout::findFont ( const PP_AttrProp pSpanAP,
const PP_AttrProp pBlockAP,
const PP_AttrProp pSectionAP,
bool  isField = false 
)

const GR_Font * FL_DocLayout::findFont ( const PP_AttrProp pSpanAP,
const PP_AttrProp pBlockAP,
const PP_AttrProp pSectionAP,
GR_Graphics pG,
bool  isField = false 
)

void FL_DocLayout::changeDocSections ( const PX_ChangeRecord_StruxChange pcrx,
fl_DocSectionLayout pDSL 
)

fp_Page * FL_DocLayout::addNewPage ( fl_DocSectionLayout pOwner,
bool  bNoUpdate = false