diff options
author | Vladimir Glazounov <vg@openoffice.org> | 2007-10-29 14:30:38 +0000 |
---|---|---|
committer | Vladimir Glazounov <vg@openoffice.org> | 2007-10-29 14:30:38 +0000 |
commit | fbbf04ae07ba83295b8f53700b2302b5445c1440 (patch) | |
tree | 386532659d5a37908fc818264c006d6e4293dec6 /writerfilter/source/dmapper/DomainMapperTableManager.cxx | |
parent | ed0abb54904de63aee542ab47b2dc59fb9e2c728 (diff) |
#100000# fix repository
Diffstat (limited to 'writerfilter/source/dmapper/DomainMapperTableManager.cxx')
-rw-r--r-- | writerfilter/source/dmapper/DomainMapperTableManager.cxx | 51 |
1 files changed, 12 insertions, 39 deletions
diff --git a/writerfilter/source/dmapper/DomainMapperTableManager.cxx b/writerfilter/source/dmapper/DomainMapperTableManager.cxx index 5ee43a82bb6f..abb2f3ef3688 100644 --- a/writerfilter/source/dmapper/DomainMapperTableManager.cxx +++ b/writerfilter/source/dmapper/DomainMapperTableManager.cxx @@ -4,9 +4,9 @@ * * $RCSfile: DomainMapperTableManager.cxx,v $ * - * $Revision: 1.16 $ + * $Revision: 1.17 $ * - * last change: $Author: os $ $Date: 2007-06-29 12:43:44 $ + * last change: $Author: vg $ $Date: 2007-10-29 15:29:11 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -92,7 +92,16 @@ bool DomainMapperTableManager::sprm(doctok::Sprm & rSprm) { /* WRITERFILTERSTATUS: done: 0, planned: 2, spent: 0 */ //table justification 0: left, 1: center, 2: right - sal_Int16 nOrient = ConversionHelper::convertTableJustification( nIntValue ); + sal_Int16 nOrient = text::HoriOrientation::LEFT_AND_WIDTH; + switch( nIntValue ) + { + case 1 : nOrient = text::HoriOrientation::CENTER; break; + case 2 : nOrient = text::HoriOrientation::RIGHT; break; + case 0 : + //no break + default:; + + } PropertyMapPtr pTableMap( new PropertyMap ); pTableMap->Insert( PROP_HORI_ORIENT, false, uno::makeAny( nOrient ) ); insertTableProps( pTableMap ); @@ -370,42 +379,6 @@ void DomainMapperTableManager::clearData() m_bFullWidth = false; m_aCellWidths.clear(); m_sTableStyleName = ::rtl::OUString(); - m_pTableStyleTextProperies.reset(); } -/*-- 27.06.2007 14:19:50--------------------------------------------------- - - -----------------------------------------------------------------------*/ -void lcl_CopyTextProperties(PropertyMapPtr pToFill, - const StyleSheetEntry* pStyleSheetEntry, StyleSheetTablePtr pStyleSheetTable) -{ - //fill base style properties first, recursively - if( pStyleSheetEntry->sBaseStyleIdentifier.getLength()) - { - const StyleSheetEntry* pParentStyleSheet = - pStyleSheetTable->FindStyleSheetByISTD(pStyleSheetEntry->sBaseStyleIdentifier); - OSL_ENSURE( pParentStyleSheet, "table style not found" ); - lcl_CopyTextProperties( pToFill, pParentStyleSheet, pStyleSheetTable); - } - PropertyMap::const_iterator aPropIter = pStyleSheetEntry->pProperties->begin(); - while(aPropIter != pStyleSheetEntry->pProperties->end()) - { - //copy all text properties form the table style to the current run attributes - if( aPropIter->first.bIsTextProperty ) - pToFill->insert(*aPropIter); - ++aPropIter; - } -} -void DomainMapperTableManager::CopyTextProperties(PropertyMapPtr pContext, StyleSheetTablePtr pStyleSheetTable) -{ - if( !m_pTableStyleTextProperies.get()) - { - m_pTableStyleTextProperies.reset( new PropertyMap ); - const StyleSheetEntry* pStyleSheetEntry = pStyleSheetTable->FindStyleSheetByISTD( - m_sTableStyleName); - OSL_ENSURE( pStyleSheetEntry, "table style not found" ); - lcl_CopyTextProperties(m_pTableStyleTextProperies, pStyleSheetEntry, pStyleSheetTable); - } - pContext->insert( m_pTableStyleTextProperies ); -} } |