#include <OXML_Section.h>
OXML_Section::OXML_Section | ( | ) |
References m_children, m_footerIds, and m_headerIds.
OXML_Section::OXML_Section | ( | const std::string & | id | ) |
References m_children, m_footerIds, and m_headerIds.
OXML_Section::~OXML_Section | ( | ) | [virtual] |
References clearChildren(), m_footerIds, and m_headerIds.
UT_Error OXML_Section::_setReferenceIds | ( | ) | [private] |
UT_Error OXML_Section::addToPT | ( | PD_Document * | pDocument | ) |
Appends this section and all its content to the Abiword Piecetable.
This method is used during the import process.
pDocument | A valid reference to the PD_Document object. |
References _setReferenceIds(), PD_Document::appendSpan(), PD_Document::appendStrux(), EVENPAGE_BREAK, OXML_ObjectWithAttrProp::getAttributesWithProps(), m_breakType, m_children, NEXTPAGE_BREAK, ODDPAGE_BREAK, PTX_Section, UT_OK, and UT_return_val_if_fail.
UT_Error OXML_Section::addToPTAsEndnote | ( | PD_Document * | pDocument | ) |
References PD_Document::appendObject(), PD_Document::appendStrux(), m_children, m_id, PTO_Field, PTX_EndEndnote, PTX_SectionEndnote, UT_ERROR, UT_OK, and UT_return_val_if_fail.
Referenced by OXML_Element_Field::addToPT().
UT_Error OXML_Section::addToPTAsFootnote | ( | PD_Document * | pDocument | ) |
References PD_Document::appendObject(), PD_Document::appendStrux(), m_children, m_id, PTO_Field, PTX_EndFootnote, PTX_SectionFootnote, UT_ERROR, UT_OK, and UT_return_val_if_fail.
Referenced by OXML_Element_Field::addToPT().
UT_Error OXML_Section::addToPTAsHdrFtr | ( | PD_Document * | pDocument | ) |
UT_Error OXML_Section::appendElement | ( | OXML_SharedElement | obj | ) |
References m_children, m_target, UT_DEBUGMSG, and UT_return_val_if_fail.
Referenced by IE_Exp_OpenXML_Listener::populateStrux().
void OXML_Section::applyDocumentProperties | ( | ) |
References gchar, OXML_Document::getInstance(), OXML_ObjectWithAttrProp::getProperty(), OXML_Document::setColumns(), OXML_Document::setPageMargins(), and UT_OK.
Referenced by serialize().
UT_Error OXML_Section::clearChildren | ( | ) |
References m_children, and UT_OK.
Referenced by ~OXML_Section().
OXML_SectionBreakType OXML_Section::getBreakType | ( | ) | const [inline] |
References m_breakType.
OXML_SharedElement OXML_Section::getElement | ( | const std::string & | id | ) |
References m_children.
const char* OXML_Section::getFooterId | ( | OXML_HeaderFooterType | type | ) | const [inline] |
References m_footerIds.
bool OXML_Section::getHandledHdrFtr | ( | ) | const [inline] |
References m_handledHdrFtr.
const char* OXML_Section::getHeaderId | ( | OXML_HeaderFooterType | type | ) | const [inline] |
References m_headerIds.
const std::string& OXML_Section::getId | ( | ) | const [inline] |
References m_id.
bool OXML_Section::hasEvenPageHdrFtr | ( | ) | const |
References gchar, OXML_ObjectWithAttrProp::getAttribute(), and UT_OK.
bool OXML_Section::hasFirstPageHdrFtr | ( | ) | const |
References gchar, OXML_ObjectWithAttrProp::getAttribute(), and UT_OK.
bool OXML_Section::operator== | ( | const std::string & | id | ) |
References m_id.
UT_Error OXML_Section::serialize | ( | IE_Exp_OpenXML * | exporter | ) |
Writes the OpenXML section and all its content to a file on disk.
This method is used during the export process.
exporter | the actual exporter which handles writing the files. |
References applyDocumentProperties(), OXML_Document::getInstance(), OXML_Document::getLastSection(), m_children, m_lastParagraph, and UT_OK.
UT_Error OXML_Section::serializeEndnote | ( | IE_Exp_OpenXML * | exporter | ) |
Serialize the section as a endnote.
References IE_Exp_OpenXML::finishEndnote(), gchar, OXML_ObjectWithAttrProp::getAttribute(), m_children, IE_Exp_OpenXML::startEndnote(), and UT_OK.
UT_Error OXML_Section::serializeFooter | ( | IE_Exp_OpenXML * | exporter | ) |
Serialize the section as a footer.
References IE_Exp_OpenXML::finishFooterStream(), gchar, OXML_ObjectWithAttrProp::getAttribute(), m_children, IE_Exp_OpenXML::setFooterReference(), IE_Exp_OpenXML::setFooterRelation(), IE_Exp_OpenXML::startFooterStream(), TARGET_FOOTER, type, and UT_OK.
UT_Error OXML_Section::serializeFootnote | ( | IE_Exp_OpenXML * | exporter | ) |
Serialize the section as a footnote.
References IE_Exp_OpenXML::finishFootnote(), gchar, OXML_ObjectWithAttrProp::getAttribute(), m_children, IE_Exp_OpenXML::startFootnote(), and UT_OK.
UT_Error OXML_Section::serializeHeader | ( | IE_Exp_OpenXML * | exporter | ) |
Serialize the section as a header.
References IE_Exp_OpenXML::finishHeaderStream(), gchar, OXML_ObjectWithAttrProp::getAttribute(), m_children, IE_Exp_OpenXML::setHeaderReference(), IE_Exp_OpenXML::setHeaderRelation(), IE_Exp_OpenXML::startHeaderStream(), type, and UT_OK.
UT_Error OXML_Section::serializeProperties | ( | IE_Exp_OpenXML * | exporter, | |
OXML_Element_Paragraph * | pParagraph | |||
) |
References IE_Exp_OpenXML::finishSectionProperties(), gchar, OXML_ObjectWithAttrProp::getAttribute(), OXML_Document::getHdrFtrById(), OXML_Document::getInstance(), OXML_ObjectWithAttrProp::getProperty(), OXML_Document::isAllDefault(), m_lastParagraph, m_target, IE_Exp_OpenXML::setColumns(), IE_Exp_OpenXML::setContinuousSection(), IE_Exp_OpenXML::setPageMargins(), IE_Exp_OpenXML::startSectionProperties(), and UT_OK.
Referenced by OXML_Element_Paragraph::serializeProperties().
void OXML_Section::setBreakType | ( | OXML_SectionBreakType | br | ) | [inline] |
References m_breakType.
void OXML_Section::setChildren | ( | OXML_ElementVector | c | ) | [inline] |
References m_children.
void OXML_Section::setFooterId | ( | const char * | id, | |
OXML_HeaderFooterType | type | |||
) | [inline] |
References m_footerIds.
void OXML_Section::setHandledHdrFtr | ( | bool | val | ) | [inline] |
References m_handledHdrFtr.
void OXML_Section::setHeaderId | ( | const char * | id, | |
OXML_HeaderFooterType | type | |||
) | [inline] |
References m_headerIds.
UT_Error OXML_Section::setPageMargins | ( | const std::string & | top, | |
const std::string & | left, | |||
const std::string & | right, | |||
const std::string & | bottom | |||
) |
References OXML_ObjectWithAttrProp::setProperty(), and UT_OK.
void OXML_Section::setTarget | ( | int | target | ) |
References m_target.
Referenced by IE_Exp_OpenXML_Listener::populateStrux().
bool operator== | ( | const OXML_SharedSection & | lhs, | |
const std::string & | id | |||
) | [friend] |
Referenced by addToPT(), getBreakType(), and setBreakType().
OXML_ElementVector OXML_Section::m_children [private] |
char* OXML_Section::m_footerIds[3] [private] |
Referenced by _setReferenceIds(), getFooterId(), OXML_Section(), setFooterId(), and ~OXML_Section().
bool OXML_Section::m_handledHdrFtr [private] |
Referenced by getHandledHdrFtr(), and setHandledHdrFtr().
char* OXML_Section::m_headerIds[3] [private] |
Referenced by _setReferenceIds(), getHeaderId(), OXML_Section(), setHeaderId(), and ~OXML_Section().
std::string OXML_Section::m_id [private] |
Referenced by addToPTAsEndnote(), addToPTAsFootnote(), getId(), and operator==().
Referenced by serialize(), and serializeProperties().
int OXML_Section::m_target [private] |
Referenced by appendElement(), serializeProperties(), and setTarget().