25#include <ooxml/resourceids.hxx>
35m_rDMapper( rDMapper ),
73 case NS_ooxml::LN_CT_TblStyleOverrideType:
77 case NS_ooxml::LN_Value_ST_TblStyleOverrideType_wholeTable:
80 case NS_ooxml::LN_Value_ST_TblStyleOverrideType_firstRow:
83 case NS_ooxml::LN_Value_ST_TblStyleOverrideType_lastRow:
86 case NS_ooxml::LN_Value_ST_TblStyleOverrideType_firstCol:
89 case NS_ooxml::LN_Value_ST_TblStyleOverrideType_lastCol:
92 case NS_ooxml::LN_Value_ST_TblStyleOverrideType_band1Vert:
95 case NS_ooxml::LN_Value_ST_TblStyleOverrideType_band2Vert:
98 case NS_ooxml::LN_Value_ST_TblStyleOverrideType_band1Horz:
101 case NS_ooxml::LN_Value_ST_TblStyleOverrideType_band2Horz:
104 case NS_ooxml::LN_Value_ST_TblStyleOverrideType_neCell:
107 case NS_ooxml::LN_Value_ST_TblStyleOverrideType_nwCell:
110 case NS_ooxml::LN_Value_ST_TblStyleOverrideType_seCell:
113 case NS_ooxml::LN_Value_ST_TblStyleOverrideType_swCell:
129 switch ( rSprm.
getId( ) )
131 case NS_ooxml::LN_CT_PPrBase:
132 case NS_ooxml::LN_EG_RPrBase:
133 case NS_ooxml::LN_CT_TblPrBase:
134 case NS_ooxml::LN_CT_TrPrBase:
135 case NS_ooxml::LN_CT_TcPrBase:
137 std::vector<beans::PropertyValue> aSavedGrabBag;
138 bool bGrabBag = rSprm.
getId() == NS_ooxml::LN_CT_PPrBase ||
139 rSprm.
getId() == NS_ooxml::LN_EG_RPrBase ||
140 rSprm.
getId() == NS_ooxml::LN_CT_TblPrBase ||
141 rSprm.
getId() == NS_ooxml::LN_CT_TrPrBase ||
142 rSprm.
getId() == NS_ooxml::LN_CT_TcPrBase;
150 if (rSprm.
getId() == NS_ooxml::LN_CT_PPrBase)
152 else if (rSprm.
getId() == NS_ooxml::LN_EG_RPrBase)
154 else if (rSprm.
getId() == NS_ooxml::LN_CT_TblPrBase)
156 else if (rSprm.
getId() == NS_ooxml::LN_CT_TrPrBase)
158 else if (rSprm.
getId() == NS_ooxml::LN_CT_TcPrBase)
164 case NS_ooxml::LN_CT_TrPrBase_tblHeader:
167 beans::PropertyValue aValue;
168 aValue.Name =
"tblHeader";
169 aValue.Value <<=
true;
173 case NS_ooxml::LN_CT_TblPrBase_tblInd:
180 pProperties->resolve(*pMeasureHandler);
187 case NS_ooxml::LN_CT_TblPrBase_tblCellMar:
192 auto pCellMarginHandler = std::make_shared<CellMarginHandler>();
193 pCellMarginHandler->enableInteropGrabBag(
"tblCellMar");
194 pProperties->resolve( *pCellMarginHandler );
197 if( pCellMarginHandler->m_bTopMarginValid )
199 if( pCellMarginHandler->m_bBottomMarginValid )
201 if( pCellMarginHandler->m_bLeftMarginValid )
203 if( pCellMarginHandler->m_bRightMarginValid )
222 if (aGrabBag.hasElements())
237 pProperties->resolve(*
this);
242 beans::PropertyValue aProperty;
243 aProperty.Name = aKey;
244 aProperty.Value <<= aValue;
250 beans::PropertyValue aRet;
void sprm(Sprm &sprm) override
Receives a SPRM.
An SPRM: Section, Paragraph and Run Modifier.
virtual sal_uInt32 getId() const =0
Returns id of the SPRM.
virtual writerfilter::Reference< Properties >::Pointer_t getProps()=0
Returns reference to properties contained in the SPRM.
virtual std::string toString() const =0
Returns string representation of sprm.
static TagLogger & getInstance()
void startElement(const std::string &name)
void attribute(const std::string &name, const std::string &value)
virtual int getInt() const =0
Returns integer representation of the value.
void enableInteropGrabBag(const OUString &aName)
Enable storing of seen tokens in a named grab bag.
void PopStyleSheetProperties(bool bAffectTableMngr=false)
void PushStyleSheetProperties(const PropertyMapPtr &pStyleProperties, bool bAffectTableMngr=false)
css::beans::PropertyValue getInteropGrabBag()
Get the stored tokens and clear the internal storage.
Handler for sprms that contain a measure and a unit.
void resolveSprmProps(Sprm &rSprm)
std::vector< css::beans::PropertyValue > m_aInteropGrabBag
DomainMapper & m_rDMapper
virtual void lcl_attribute(Id Name, Value &val) override
PropertyMapPtr m_pProperties
virtual ~TblStylePrHandler() override
void appendInteropGrabBag(const OUString &aKey, const OUString &aValue)
std::unique_ptr< TablePropertiesHandler > m_pTablePropsHandler
TblStylePrHandler(DomainMapper &rDMapper)
virtual void lcl_sprm(Sprm &sprm) override
css::beans::PropertyValue getInteropGrabBag(const OUString &aName)
OUString getTypeString() const
css::uno::Sequence< DstElementType > containerToSequence(const SrcType &i_Container)
@ META_PROP_CELL_MAR_RIGHT
@ META_PROP_CELL_MAR_BOTTOM
@ META_PROP_CELL_MAR_LEFT