summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
Diffstat (limited to 'sc')
-rw-r--r--sc/source/filter/inc/stylesbuffer.hxx2
-rw-r--r--sc/source/filter/oox/stylesbuffer.cxx19
2 files changed, 4 insertions, 17 deletions
diff --git a/sc/source/filter/inc/stylesbuffer.hxx b/sc/source/filter/inc/stylesbuffer.hxx
index 5701244767b9..6b78bc08b37e 100644
--- a/sc/source/filter/inc/stylesbuffer.hxx
+++ b/sc/source/filter/inc/stylesbuffer.hxx
@@ -678,7 +678,7 @@ public:
/** Writes all formatting attributes to the passed property set. */
void writeToPropertySet( PropertySet& rPropSet ) const;
- void writeToDoc( ScDocumentImport& rDoc, const css::table::CellRangeAddress& rRange ) const;
+ void writeToDoc( ScDocumentImport& rDoc, const css::table::CellRangeAddress& rRange );
const ::ScPatternAttr& createPattern( bool bSkipPoolDefs = false );
diff --git a/sc/source/filter/oox/stylesbuffer.cxx b/sc/source/filter/oox/stylesbuffer.cxx
index bf63786e9725..88a4a868c813 100644
--- a/sc/source/filter/oox/stylesbuffer.cxx
+++ b/sc/source/filter/oox/stylesbuffer.cxx
@@ -2252,7 +2252,7 @@ void Xf::writeToPropertySet( PropertySet& rPropSet ) const
rPropSet.setProperties( aPropMap );
}
-void Xf::writeToDoc( ScDocumentImport& rDoc, const table::CellRangeAddress& rRange ) const
+void Xf::writeToDoc( ScDocumentImport& rDoc, const table::CellRangeAddress& rRange )
{
const StylesBuffer& rStyles = getStyles();
@@ -2273,22 +2273,9 @@ void Xf::writeToDoc( ScDocumentImport& rDoc, const table::CellRangeAddress& rRan
}
}
- boost::scoped_ptr<ScPatternAttr> pAttr(new ScPatternAttr(rDoc.getDoc().GetPool()));
-
- {
- SvxRotateMode eRotateMode = SVX_ROTATE_MODE_STANDARD;
-
- if (maModel.mbBorderUsed && rStyles.hasBorder(maModel.mnBorderId) && maAlignment.getApiData().mnRotation)
- eRotateMode = SVX_ROTATE_MODE_BOTTOM;
-
- SvxRotateModeItem aItem(eRotateMode, ATTR_ROTATE_MODE);
- ScfTools::PutItem(pAttr->GetItemSet(), aItem, false);
- }
-
- // TODO : Move more properties from writeToPropertyMap().
-
+ const ScPatternAttr& rAttr = createPattern();
rDoc.getDoc().ApplyPatternAreaTab(
- rRange.StartColumn, rRange.StartRow, rRange.EndColumn, rRange.EndRow, rRange.Sheet, *pAttr);
+ rRange.StartColumn, rRange.StartRow, rRange.EndColumn, rRange.EndRow, rRange.Sheet, rAttr);
}
const ::ScPatternAttr&