diff options
Diffstat (limited to 'writerfilter')
-rw-r--r-- | writerfilter/source/dmapper/DomainMapperTableManager.cxx | 12 | ||||
-rw-r--r-- | writerfilter/source/dmapper/TableManager.hxx | 2 |
2 files changed, 12 insertions, 2 deletions
diff --git a/writerfilter/source/dmapper/DomainMapperTableManager.cxx b/writerfilter/source/dmapper/DomainMapperTableManager.cxx index e29637583631..3a3b713723ee 100644 --- a/writerfilter/source/dmapper/DomainMapperTableManager.cxx +++ b/writerfilter/source/dmapper/DomainMapperTableManager.cxx @@ -644,8 +644,16 @@ void DomainMapperTableManager::endOfRowAction() { if(nTableWidth > 100 || nTableWidth <= 0) { - pTablePropMap->setValue(TablePropertyMap::TABLE_WIDTH, m_nTableWidth); - pTablePropMap->setValue(TablePropertyMap::TABLE_WIDTH_TYPE, text::SizeType::FIX); + if(getTableDepth() > 1 && !m_bTableSizeTypeInserted) + { + pTablePropMap->setValue(TablePropertyMap::TABLE_WIDTH, sal_Int32(100)); + pTablePropMap->setValue(TablePropertyMap::TABLE_WIDTH_TYPE, text::SizeType::VARIABLE); + } + else + { + pTablePropMap->setValue(TablePropertyMap::TABLE_WIDTH, m_nTableWidth); + pTablePropMap->setValue(TablePropertyMap::TABLE_WIDTH_TYPE, text::SizeType::FIX); + } } } uno::Sequence< text::TableColumnSeparator > aSeparators( m_nCell.back( ) - 1 ); diff --git a/writerfilter/source/dmapper/TableManager.hxx b/writerfilter/source/dmapper/TableManager.hxx index 6c7a9ea1e21e..47947ee724ee 100644 --- a/writerfilter/source/dmapper/TableManager.hxx +++ b/writerfilter/source/dmapper/TableManager.hxx @@ -328,6 +328,8 @@ protected: */ sal_uInt32 getTableDepthDifference() const { return mnTableDepthNew - mnTableDepth; } + sal_uInt32 getTableDepth() const { return mnTableDepthNew; } + /** Action to be carried out at the end of the last paragraph of a cell. |