diff options
author | Miklos Vajna <vmiklos@suse.cz> | 2013-01-17 17:37:19 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@suse.cz> | 2013-01-17 17:44:39 +0100 |
commit | f4483d31f33aca78afbd719e58db5d8a097411dd (patch) | |
tree | 6d26a3b1db06a67a2f177e1e883992f966685874 /oox/source/vml | |
parent | 88ebaff73533fdbbd7ecbf24a0e892f411c577a0 (diff) |
VML import of TextFrame border width
Change-Id: I9c0cf277e17c02c2de564d48ba79e1c25ea23db5
Diffstat (limited to 'oox/source/vml')
-rw-r--r-- | oox/source/vml/vmlshape.cxx | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/oox/source/vml/vmlshape.cxx b/oox/source/vml/vmlshape.cxx index 0fa3a3d17996..e36d98e2b0d9 100644 --- a/oox/source/vml/vmlshape.cxx +++ b/oox/source/vml/vmlshape.cxx @@ -18,6 +18,7 @@ */ #include <algorithm> +#include <boost/optional.hpp> #include "oox/vml/vmlshape.hxx" @@ -370,7 +371,10 @@ void ShapeBase::convertShapeProperties( const Reference< XShape >& rxShape ) con aPropMap.setProperty(PROP_BackColor, aPropMap[PROP_FillColor]); aPropMap.erase(PROP_FillColor); } - // And no LineColor property; individual borders can have colors + // And no LineColor property; individual borders can have colors and widths + boost::optional<sal_Int32> oLineWidth; + if (maTypeModel.maStrokeModel.moWeight.has()) + oLineWidth.reset(ConversionHelper::decodeMeasureToHmm(rGraphicHelper, maTypeModel.maStrokeModel.moWeight.get(), 0, false, false)); if (aPropMap.hasProperty(PROP_LineColor)) { uno::Reference<beans::XPropertySet> xPropertySet(rxShape, uno::UNO_QUERY); @@ -381,6 +385,8 @@ void ShapeBase::convertShapeProperties( const Reference< XShape >& rxShape ) con { table::BorderLine2 aBorderLine = xPropertySet->getPropertyValue(PropertyMap::getPropertyName(aBorders[i])).get<table::BorderLine2>(); aBorderLine.Color = aPropMap[PROP_LineColor].get<sal_Int32>(); + if (oLineWidth) + aBorderLine.LineWidth = *oLineWidth; aPropMap.setProperty(aBorders[i], uno::makeAny(aBorderLine)); } aPropMap.erase(PROP_LineColor); |