#include <fl_TableLayout.h>
fl_CellLayout::fl_CellLayout | ( | FL_DocLayout * | pLayout, | |
pf_Frag_Strux * | sdh, | |||
PT_AttrPropIndex | ap, | |||
fl_ContainerLayout * | pMyContainerLayout | |||
) |
References createCellContainer().
fl_CellLayout::~fl_CellLayout | ( | ) | [virtual] |
void fl_CellLayout::_localCollapse | ( | void | ) | [private] |
void fl_CellLayout::_lookupProperties | ( | const PP_AttrProp * | pSectionAP | ) | [protected, virtual] |
this function is only to be called by fl_ContainerLayout::lookupProperties() all other code must call lookupProperties() instead
Implements fl_ContainerLayout.
References AP_PREF_KEY_RulerUnits, dim, DIM_CM, DIM_IN, DIM_MM, DIM_none, DIM_PERCENT, DIM_PI, DIM_PT, DIM_PX, FP_HIDDEN_FOLDED, gchar, XAP_App::getApp(), getBottomAttach(), fl_TableLayout::getBottomStyle(), UT_GenericVector< T >::getItemCount(), getLeftAttach(), fl_TableLayout::getLeftStyle(), UT_GenericVector< T >::getNthItem(), PP_AttrProp::getProperty(), getRightAttach(), fl_TableLayout::getRightStyle(), getTopAttach(), fl_TableLayout::getTopStyle(), fl_TableLayout::getVecColProps(), fl_TableLayout::getVecRowProps(), fl_ContainerLayout::isHidden(), fl_Layout::m_apIndex, m_background, m_dBottomOffsetUserUnits, m_dLeftOffsetUserUnits, m_dRightOffsetUserUnits, m_dTopOffsetUserUnits, m_iBottomAttach, m_iBottomOffset, m_iCellHeight, m_iCellWidth, fl_ColProps::m_iColWidth, m_iLeftAttach, m_iLeftOffset, m_iRightAttach, m_iRightOffset, fl_RowProps::m_iRowHeight, m_iTopAttach, m_iTopOffset, m_iVertAlign, m_lineBottom, m_lineLeft, m_lineRight, m_lineTop, fl_ContainerLayout::myContainingLayout(), PP_PropertyMap::Background::reset(), s_background_properties(), s_border_properties_cell(), UT_convertDimensionless(), UT_convertToLogicalUnits(), UT_DEBUGMSG, UT_determineDimension(), UT_return_if_fail, and xxx_UT_DEBUGMSG.
void fl_CellLayout::_purgeLayout | ( | void | ) | [protected, virtual] |
This method removes all layout structures contained by this layout structure.
Reimplemented from fl_SectionLayout.
References fl_ContainerLayout::getFirstLayout(), and fl_ContainerLayout::getNext().
Referenced by ~fl_CellLayout().
void fl_CellLayout::_updateCell | ( | void | ) | [private] |
bool fl_CellLayout::bl_doclistener_insertCell | ( | fl_ContainerLayout * | pCell, | |
const PX_ChangeRecord_Strux * | pcrx, | |||
pf_Frag_Strux * | sdh, | |||
PL_ListenerId | lid, | |||
void(*)(pf_Frag_Strux *sdhNew, PL_ListenerId lid, fl_ContainerLayout *sfhNew) | pfnBindHandles | |||
) | [virtual] |
References fl_TableLayout::attachCell(), PX_ChangeRecord::getIndexAP(), FV_View::getPoint(), PX_ChangeRecord::getPosition(), FL_DocLayout::getView(), fl_ContainerLayout::insert(), FV_View::isActive(), FV_View::isPreview(), fl_SectionLayout::m_pLayout, fl_ContainerLayout::myContainingLayout(), FV_View::setPoint(), and FV_View::updateCarets().
bool fl_CellLayout::bl_doclistener_insertEndCell | ( | fl_ContainerLayout * | , | |
const PX_ChangeRecord_Strux * | pcrx, | |||
pf_Frag_Strux * | sdh, | |||
PL_ListenerId | lid, | |||
void(*)(pf_Frag_Strux *sdhNew, PL_ListenerId lid, fl_ContainerLayout *sfhNew) | pfnBindHandles | |||
) | [virtual] |
void fl_CellLayout::checkAndAdjustCellSize | ( | void | ) |
This method measures the cell height and compares it to the previously measured height. If they disagree update the layout of the table.
Reimplemented from fl_SectionLayout.
References fl_ContainerLayout::format(), fl_ContainerLayout::getFirstContainer(), _fp_Requisition::height, m_iCellHeight, m_iCellWidth, fl_ContainerLayout::myContainingLayout(), fp_CellContainer::setHeight(), fp_CellContainer::sizeRequest(), _fp_Requisition::width, and xxx_UT_DEBUGMSG.
Referenced by fl_SectionLayout::checkAndAdjustCellSize(), and format().
void fl_CellLayout::collapse | ( | void | ) | [virtual] |
Implements fl_ContainerLayout.
References _localCollapse(), fp_Container::getContainer(), fl_ContainerLayout::getFirstContainer(), fp_Container::getNext(), fp_Container::getPrev(), fp_VerticalContainer::removeContainer(), fl_ContainerLayout::setFirstContainer(), fl_ContainerLayout::setLastContainer(), fl_SectionLayout::setNeedsReformat(), fp_Container::setNext(), and fp_ContainerObject::setPrev().
Referenced by doclistener_changeStrux(), and doclistener_deleteStrux().
void fl_CellLayout::createCellContainer | ( | void | ) |
This method creates a new cell with it's properties initially set from the Attributes/properties of this Layout
References FG_Graphic::createFromStrux(), DELETEP, fp_CellContainer, FP_HIDDEN_FOLDED, gchar, fl_ContainerLayout::getAP(), PP_AttrProp::getAttribute(), fl_ContainerLayout::getContainerType(), fl_ContainerLayout::getDocSectionLayout(), fl_DocSectionLayout::getWidth(), fl_ContainerLayout::isHidden(), fl_ContainerLayout::lookupProperties(), m_iLeftAttach, fl_SectionLayout::m_pGraphicImage, fl_SectionLayout::m_pImageImage, fl_ContainerLayout::myContainingLayout(), PT_STRUX_IMAGE_DATAID, setCellContainerProperties(), fl_ContainerLayout::setFirstContainer(), fl_ContainerLayout::setLastContainer(), fp_CellContainer::setWidth(), UT_ASSERT, UT_DEBUGMSG, and xxx_UT_DEBUGMSG.
Referenced by fl_CellLayout(), and getNewContainer().
void fl_CellLayout::decNumNestedTables | ( | void | ) |
References m_iNumNestedTables.
Referenced by fl_TableLayout::doclistener_deleteStrux().
bool fl_CellLayout::doclistener_changeStrux | ( | const PX_ChangeRecord_StruxChange * | pcrxc | ) | [virtual] |
Implements fl_SectionLayout.
References _updateCell(), fl_HdrFtrSectionLayout::bl_doclistener_changeStrux(), collapse(), fl_ContainerLayout::getContainerType(), PX_ChangeRecord::getIndexAP(), PX_ChangeRecord_StruxChange::getStruxType(), PX_ChangeRecord::getType(), fl_ContainerLayout::myContainingLayout(), fl_Layout::setAttrPropIndex(), and UT_ASSERT.
Referenced by fl_DocListener::change().
bool fl_CellLayout::doclistener_deleteStrux | ( | const PX_ChangeRecord_Strux * | pcrx | ) | [virtual] |
void fl_CellLayout::format | ( | void | ) | [virtual] |
Implements fl_ContainerLayout.
References checkAndAdjustCellSize(), UT_GenericVector< T >::clear(), FL_CONTAINER_HDRFTR, FL_CONTAINER_SHADOW, fl_ContainerLayout::format(), FP_HIDDEN_FOLDED, fl_ContainerLayout::getContainerType(), fl_ContainerLayout::getDocSectionLayout(), fl_ContainerLayout::getFirstContainer(), fl_ContainerLayout::getFirstLayout(), fp_ContainerObject::getHeight(), UT_GenericVector< T >::getItemCount(), fl_ContainerLayout::getLastContainer(), getNewContainer(), fl_ContainerLayout::getNext(), fp_Container::getPage(), fl_ContainerLayout::getPrev(), fl_ContainerLayout::isHidden(), m_bDoingFormat, fl_SectionLayout::m_bNeedsReformat, fl_SectionLayout::m_vecFormatLayout, fl_ContainerLayout::myContainingLayout(), fl_ContainerLayout::setNeedsReformat(), fl_DocSectionLayout::setNeedsSectionBreak(), UT_DEBUGMSG, and xxx_UT_DEBUGMSG.
Referenced by _updateCell(), fl_TableLayout::doSimpleChange(), fp_CellContainer::setWidth(), and updateLayout().
UT_sint32 fl_CellLayout::getBottomAttach | ( | void | ) | const [inline] |
References fp_CellContainer::m_iBottomAttach.
Referenced by _lookupProperties(), FV_View::cmdInsertCol(), and FV_View::cmdInsertRow().
UT_sint32 fl_CellLayout::getBottomOffset | ( | void | ) | const |
References m_iBottomOffset.
UT_sint32 fl_CellLayout::getCellHeight | ( | void | ) | const [inline] |
UT_sint32 fl_CellLayout::getCellWidth | ( | void | ) | const [inline] |
UT_sint32 fl_CellLayout::getLeftAttach | ( | void | ) | const [inline] |
UT_sint32 fl_CellLayout::getLeftOffset | ( | void | ) | const |
References m_iLeftOffset.
UT_uint32 fl_CellLayout::getLength | ( | void | ) |
Return the total length of the cell including nested tables. This length includes the cell and endcell struxs so if you add it to the position of the cell strux you will get the first position past the endcell strux
References PD_Document::getBounds(), PD_Document::getEndCellStruxFromCellSDH(), fl_Layout::getStruxDocHandle(), PD_Document::getStruxPosition(), and fl_Layout::m_pDoc.
Referenced by FV_VisualDragText::getImageFromSelection().
fp_Container * fl_CellLayout::getNewContainer | ( | fp_Container * | pPrev = NULL |
) | [virtual] |
Create a new Cell containers and plug it into the linked list of Cell containers.
If | pPrevCell is non-null place the new cell after this in the linked list, otherwise just append it to the end. |
Implements fl_SectionLayout.
References createCellContainer(), fl_ContainerLayout::getFirstContainer(), fl_ContainerLayout::getLastContainer(), setCellContainerProperties(), UT_ASSERT, and UT_UNUSED.
Referenced by format().
UT_sint32 fl_CellLayout::getNumNestedTables | ( | void | ) | const |
References m_iNumNestedTables.
Referenced by fp_CellContainer::containsNestedTables().
UT_sint32 fl_CellLayout::getRightAttach | ( | void | ) | const [inline] |
References fp_CellContainer::m_iRightAttach.
Referenced by _lookupProperties(), FV_View::cmdInsertCol(), and FV_View::cmdInsertRow().
UT_sint32 fl_CellLayout::getRightOffset | ( | void | ) | const |
References m_iRightOffset.
fl_SectionLayout * fl_CellLayout::getSectionLayout | ( | void | ) | const [virtual] |
Implements fl_ContainerLayout.
References fl_ContainerLayout::getContainerType(), and fl_ContainerLayout::myContainingLayout().
UT_sint32 fl_CellLayout::getTopAttach | ( | void | ) | const [inline] |
UT_sint32 fl_CellLayout::getTopOffset | ( | void | ) | const |
References m_iTopOffset.
void fl_CellLayout::incNumNestedTables | ( | void | ) |
References m_iNumNestedTables.
Referenced by fl_ContainerLayout::insert().
bool fl_CellLayout::isCellSelected | ( | void | ) |
Returns true if the cell is selected.
References PD_Document::getNextStruxOfType(), fl_Layout::getStruxDocHandle(), PD_Document::getStruxPosition(), FL_DocLayout::getView(), FV_View::isPosSelected(), m_iLeftAttach, m_iTopAttach, fl_Layout::m_pDoc, fl_SectionLayout::m_pLayout, PTX_EndCell, UT_return_val_if_fail, and xxx_UT_DEBUGMSG.
Referenced by fp_TextRun::_draw(), and FV_View::_drawOrClearBetweenPositions().
bool fl_CellLayout::isDoingFormat | ( | void | ) | const |
References m_bDoingFormat.
Referenced by fl_BlockLayout::format().
bool fl_CellLayout::isLayedOut | ( | void | ) | const |
References fp_ContainerObject::getContainerType(), fl_ContainerLayout::getFirstContainer(), fp_CellContainer::getStartY(), and UT_return_val_if_fail.
Referenced by needsReformat().
void fl_CellLayout::markAllRunsDirty | ( | void | ) | [virtual] |
Implements fl_SectionLayout.
References fl_ContainerLayout::getFirstLayout(), fl_ContainerLayout::getNext(), and fl_ContainerLayout::markAllRunsDirty().
Referenced by _updateCell().
bool fl_CellLayout::needsReformat | ( | void | ) | const [virtual] |
Reimplemented from fl_SectionLayout.
References isLayedOut(), and fl_SectionLayout::needsReformat().
Referenced by fl_TableLayout::needsReformat().
bool fl_CellLayout::recalculateFields | ( | UT_uint32 | iUpdateCount | ) | [virtual] |
Reimplemented from fl_SectionLayout.
References fl_ContainerLayout::getFirstLayout(), fl_ContainerLayout::getNext(), and fl_ContainerLayout::recalculateFields().
void fl_CellLayout::redrawUpdate | ( | void | ) | [virtual] |
void fl_CellLayout::setCellContainerProperties | ( | fp_CellContainer * | pCell | ) |
This method sets all the parameters of the cell container from properties of this section
References fl_ContainerLayout::getAP(), fl_SectionLayout::getDocLayout(), fp_Container::getFillType(), FL_DocLayout::getGraphics(), FL_DocLayout::getGraphicTick(), m_background, m_iBottomAttach, m_iBottomOffset, fl_SectionLayout::m_iDocImageHeight, fl_SectionLayout::m_iDocImageWidth, fl_SectionLayout::m_iGraphicTick, m_iLeftAttach, m_iLeftOffset, m_iRightAttach, m_iRightOffset, m_iTopAttach, m_iTopOffset, m_iVertAlign, m_lineBottom, m_lineLeft, m_lineRight, m_lineTop, fl_SectionLayout::m_pGraphicImage, fl_SectionLayout::m_pImageImage, GR_Image::scaleImageTo(), fp_CellContainer::setBackground(), fp_CellContainer::setBotPad(), fp_CellContainer::setBottomAttach(), fp_CellContainer::setBottomStyle(), fg_FillType::setImagePointer(), fp_CellContainer::setLeftAttach(), fp_CellContainer::setLeftPad(), fp_CellContainer::setLeftStyle(), fp_CellContainer::setRightAttach(), fp_CellContainer::setRightPad(), fp_CellContainer::setRightStyle(), fp_CellContainer::setTopAttach(), fp_CellContainer::setTopPad(), fp_CellContainer::setTopStyle(), fp_CellContainer::setVertAlign(), and GR_Graphics::tlu().
Referenced by createCellContainer(), and getNewContainer().
void fl_CellLayout::updateLayout | ( | bool | bDoFull | ) | [virtual] |
friend class fl_DocListener [friend] |
Reimplemented from fl_SectionLayout.
friend class fp_CellContainer [friend] |
Referenced by createCellContainer().
friend class fp_TableContainer [friend] |
Referenced by _lookupProperties(), and setCellContainerProperties().
bool fl_CellLayout::m_bCellPositionedOnPage [private] |
bool fl_CellLayout::m_bDoingFormat [private] |
Referenced by format(), and isDoingFormat().
bool fl_CellLayout::m_bNeedsRebuild [private] |
double fl_CellLayout::m_dBottomOffsetUserUnits [private] |
Referenced by _lookupProperties().
double fl_CellLayout::m_dLeftOffsetUserUnits [private] |
Referenced by _lookupProperties().
double fl_CellLayout::m_dRightOffsetUserUnits [private] |
Referenced by _lookupProperties().
double fl_CellLayout::m_dTopOffsetUserUnits [private] |
Referenced by _lookupProperties().
UT_sint32 fl_CellLayout::m_iBottomAttach [private] |
Referenced by _lookupProperties(), and setCellContainerProperties().
UT_sint32 fl_CellLayout::m_iBottomOffset [private] |
Referenced by _lookupProperties(), getBottomOffset(), and setCellContainerProperties().
UT_sint32 fl_CellLayout::m_iCellHeight [private] |
Referenced by _lookupProperties(), and checkAndAdjustCellSize().
UT_sint32 fl_CellLayout::m_iCellWidth [private] |
Referenced by _lookupProperties(), and checkAndAdjustCellSize().
UT_sint32 fl_CellLayout::m_iLeftAttach [private] |
Referenced by _lookupProperties(), createCellContainer(), isCellSelected(), and setCellContainerProperties().
UT_sint32 fl_CellLayout::m_iLeftOffset [private] |
Referenced by _lookupProperties(), getLeftOffset(), and setCellContainerProperties().
UT_sint32 fl_CellLayout::m_iNumNestedTables [private] |
Referenced by decNumNestedTables(), getNumNestedTables(), and incNumNestedTables().
UT_sint32 fl_CellLayout::m_iRightAttach [private] |
Referenced by _lookupProperties(), and setCellContainerProperties().
UT_sint32 fl_CellLayout::m_iRightOffset [private] |
Referenced by _lookupProperties(), getRightOffset(), and setCellContainerProperties().
UT_sint32 fl_CellLayout::m_iTopAttach [private] |
Referenced by _lookupProperties(), isCellSelected(), and setCellContainerProperties().
UT_sint32 fl_CellLayout::m_iTopOffset [private] |
Referenced by _lookupProperties(), getTopOffset(), and setCellContainerProperties().
UT_sint32 fl_CellLayout::m_iVertAlign [private] |
Referenced by _lookupProperties(), and setCellContainerProperties().
Referenced by _lookupProperties(), and setCellContainerProperties().
Referenced by _lookupProperties(), and setCellContainerProperties().
Referenced by _lookupProperties(), and setCellContainerProperties().
PP_PropertyMap::Line fl_CellLayout::m_lineTop [private] |
Referenced by _lookupProperties(), and setCellContainerProperties().