Lines 221-228
Link Here
|
221 |
pToFill->insert( pToAdd ); |
221 |
pToFill->insert( pToAdd ); |
222 |
} |
222 |
} |
223 |
|
223 |
|
224 |
PropertyMapPtr TableStyleSheetEntry::GetLocalPropertiesFromMask( sal_Int32 nMask ) |
224 |
void TableStyleSheetEntry::MergePropertiesFromMask(const short nBit, const sal_Int32 nMask, |
|
|
225 |
const TblStyleType nStyleId, |
226 |
PropertyMapPtr pToFill) |
225 |
{ |
227 |
{ |
|
|
228 |
TblStylePrs::iterator pIt = m_aStyles.find( nStyleId ); |
229 |
|
230 |
short nTestBit = 1 << nBit; |
231 |
sal_Int32 nBitMask = sal_Int32( nTestBit ); |
232 |
if ( ( nMask & nBitMask ) && ( pIt != m_aStyles.end( ) ) ) |
233 |
lcl_mergeProps( pToFill, pIt->second, nStyleId ); |
234 |
} |
235 |
|
236 |
PropertyMapPtr TableStyleSheetEntry::GetLocalPropertiesFromMask( const sal_Int32 nMask ) |
237 |
{ |
226 |
// Order from right to left |
238 |
// Order from right to left |
227 |
static TblStyleType aBitsOrder[] = |
239 |
static TblStyleType aBitsOrder[] = |
228 |
{ |
240 |
{ |
Lines 243-263
Link Here
|
243 |
|
255 |
|
244 |
// Get the properties applying according to the mask |
256 |
// Get the properties applying according to the mask |
245 |
PropertyMapPtr pProps( new PropertyMap( ) ); |
257 |
PropertyMapPtr pProps( new PropertyMap( ) ); |
246 |
short nBit = 0; |
258 |
short nBit = 4; |
247 |
do |
259 |
do |
248 |
{ |
260 |
{ |
249 |
TblStyleType nStyleId = aBitsOrder[nBit]; |
261 |
MergePropertiesFromMask(nBit, nMask, aBitsOrder[nBit], pProps); |
250 |
TblStylePrs::iterator pIt = m_aStyles.find( nStyleId ); |
|
|
251 |
|
252 |
short nTestBit = 1 << nBit; |
253 |
sal_Int32 nBitMask = sal_Int32( nTestBit ); |
254 |
if ( ( nMask & nBitMask ) && ( pIt != m_aStyles.end( ) ) ) |
255 |
lcl_mergeProps( pProps, pIt->second, nStyleId ); |
256 |
|
257 |
nBit++; |
262 |
nBit++; |
258 |
} |
263 |
} |
259 |
while ( nBit < 13 ); |
264 |
while ( nBit < 13 ); |
260 |
|
265 |
|
|
|
266 |
nBit = 0; |
267 |
do |
268 |
{ |
269 |
MergePropertiesFromMask(nBit, nMask, aBitsOrder[nBit], pProps); |
270 |
nBit++; |
271 |
} |
272 |
while ( nBit < 4 ); // nw/ne/sw/se overwrite others |
273 |
|
261 |
return pProps; |
274 |
return pProps; |
262 |
} |
275 |
} |
263 |
|
276 |
|
Lines 543-551
Link Here
|
543 |
case NS_ooxml::LN_CT_Style_personalReply: |
556 |
case NS_ooxml::LN_CT_Style_personalReply: |
544 |
case NS_ooxml::LN_CT_Style_rsid: |
557 |
case NS_ooxml::LN_CT_Style_rsid: |
545 |
case NS_ooxml::LN_CT_Style_trPr: |
558 |
case NS_ooxml::LN_CT_Style_trPr: |
546 |
case NS_ooxml::LN_CT_Style_tcPr: |
|
|
547 |
/* WRITERFILTERSTATUS: done: 0, planned: 0, spent: 0 */ |
559 |
/* WRITERFILTERSTATUS: done: 0, planned: 0, spent: 0 */ |
548 |
break; |
560 |
break; |
|
|
561 |
case NS_ooxml::LN_CT_Style_tcPr: |
562 |
{ |
563 |
resolveSprmProps(rSprm); |
564 |
} |
565 |
break; |
549 |
case NS_ooxml::LN_CT_Style_tblPr: //contains table properties |
566 |
case NS_ooxml::LN_CT_Style_tblPr: //contains table properties |
550 |
case NS_ooxml::LN_CT_Style_tblStylePr: //contains to table properties |
567 |
case NS_ooxml::LN_CT_Style_tblStylePr: //contains to table properties |
551 |
|
568 |
|