[Libreoffice-commits] .: 2 commits - sw/source writerfilter/source
Lubos Lunak
llunak at kemper.freedesktop.org
Fri May 4 11:21:25 PDT 2012
sw/source/core/unocore/unosett.cxx | 1 -
writerfilter/source/dmapper/GraphicHelpers.cxx | 12 ++++++++----
2 files changed, 8 insertions(+), 5 deletions(-)
New commits:
commit 20a8768b1c6a6a1456cda9cd096a304e16473fbb
Author: LuboÅ¡ LuÅák <l.lunak at suse.cz>
Date: Fri May 4 20:17:44 2012 +0200
.docx wrap values mean different things than in LO, map them (bnc#750838)
Change-Id: Ic355ae9993702c37c958ea16d8d97e6ef4892dcd
diff --git a/writerfilter/source/dmapper/GraphicHelpers.cxx b/writerfilter/source/dmapper/GraphicHelpers.cxx
index 551c5e9..31cded9 100644
--- a/writerfilter/source/dmapper/GraphicHelpers.cxx
+++ b/writerfilter/source/dmapper/GraphicHelpers.cxx
@@ -184,12 +184,16 @@ void WrapHandler::lcl_sprm( Sprm& )
sal_Int32 WrapHandler::getWrapMode( )
{
- sal_Int32 nMode = com::sun::star::text::WrapTextMode_NONE;
+ // The wrap values do not map directly to our wrap mode,
+ // e.g. none in .docx actually means through in LO.
+ sal_Int32 nMode = com::sun::star::text::WrapTextMode_THROUGHT;
switch ( m_nType )
{
case NS_ooxml::LN_Value_vml_wordprocessingDrawing_ST_WrapType_square:
+ // through and tight are somewhat complicated, approximate
case NS_ooxml::LN_Value_vml_wordprocessingDrawing_ST_WrapType_tight:
+ case NS_ooxml::LN_Value_vml_wordprocessingDrawing_ST_WrapType_through:
{
switch ( m_nSide )
{
@@ -204,13 +208,13 @@ sal_Int32 WrapHandler::getWrapMode( )
}
}
break;
- case NS_ooxml::LN_Value_vml_wordprocessingDrawing_ST_WrapType_through:
- nMode = com::sun::star::text::WrapTextMode_THROUGHT;
break;
case NS_ooxml::LN_Value_vml_wordprocessingDrawing_ST_WrapType_topAndBottom:
+ nMode = com::sun::star::text::WrapTextMode_NONE;
+ break;
case NS_ooxml::LN_Value_vml_wordprocessingDrawing_ST_WrapType_none:
default:
- nMode = com::sun::star::text::WrapTextMode_NONE;
+ nMode = com::sun::star::text::WrapTextMode_THROUGHT;
}
return nMode;
commit 3badf6154b5ebc73cf47e843039b3f94ab5f8ee4
Author: LuboÅ¡ LuÅák <l.lunak at suse.cz>
Date: Fri May 4 15:50:35 2012 +0200
remove unused variable
Change-Id: If19f0a37a729ce0dd067eadd82cd42637ca0862f
diff --git a/sw/source/core/unocore/unosett.cxx b/sw/source/core/unocore/unosett.cxx
index eea9d77..ca9c4b4 100644
--- a/sw/source/core/unocore/unosett.cxx
+++ b/sw/source/core/unocore/unosett.cxx
@@ -2163,7 +2163,6 @@ void SwXNumberingRules::setPropertyValue( const OUString& rPropertyName, const A
throw(UnknownPropertyException, PropertyVetoException,
IllegalArgumentException, WrappedTargetException, RuntimeException)
{
- Any aRet;
SwNumRule* pDocRule = 0;
SwNumRule* pCreatedRule = 0;
if(!pNumRule)
More information about the Libreoffice-commits
mailing list