summaryrefslogtreecommitdiff
path: root/sw/source/filter/ww8/docxattributeoutput.cxx
diff options
context:
space:
mode:
authorJustin Luth <justin.luth@collabora.com>2023-04-10 11:22:41 -0400
committerJustin Luth <jluth@mail.com>2023-04-21 22:34:26 +0200
commit66465fe341a25652cf0eb06b8e4e24e18ea8ed3c (patch)
treefbfef22cd0d594222a21e2c52d5932227336a08f /sw/source/filter/ww8/docxattributeoutput.cxx
parent981c5b5421b5fc728e2b8140d7d52d8c8eb465e7 (diff)
NFC rename: const table::BorderLine2* rStyleProps (is not a reference)
Added with commit ae61569eea0719a882010cfbb260a1a0d690d974 Author: Jacobo Aragunde Pérez on Thu Apr 3 16:27:37 2014 +0200 oox: Do not overwrite table style properties Change-Id: I8140e3a084f3f1e2d304a4ffc62897afa6427c4a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/150771 Tested-by: Jenkins Reviewed-by: Justin Luth <jluth@mail.com>
Diffstat (limited to 'sw/source/filter/ww8/docxattributeoutput.cxx')
-rw-r--r--sw/source/filter/ww8/docxattributeoutput.cxx15
1 files changed, 9 insertions, 6 deletions
diff --git a/sw/source/filter/ww8/docxattributeoutput.cxx b/sw/source/filter/ww8/docxattributeoutput.cxx
index 3b84ee2610d3..2e456a8018fb 100644
--- a/sw/source/filter/ww8/docxattributeoutput.cxx
+++ b/sw/source/filter/ww8/docxattributeoutput.cxx
@@ -4082,7 +4082,7 @@ void DocxAttributeOutput::ParagraphStyle( sal_uInt16 nStyle )
}
static void impl_borderLine( FSHelperPtr const & pSerializer, sal_Int32 elementToken, const SvxBorderLine* pBorderLine, sal_uInt16 nDist,
- bool bWriteShadow, const table::BorderLine2* rStyleProps = nullptr )
+ bool bWriteShadow, const table::BorderLine2* pStyleProps = nullptr)
{
// Compute val attribute value
// Can be one of:
@@ -4153,7 +4153,7 @@ static void impl_borderLine( FSHelperPtr const & pSerializer, sal_Int32 elementT
break;
}
}
- else if ( !rStyleProps || !rStyleProps->LineWidth )
+ else if (!pStyleProps || !pStyleProps->LineWidth)
// no line, and no line set by the style either:
// there is no need to write the property
return;
@@ -4161,11 +4161,14 @@ static void impl_borderLine( FSHelperPtr const & pSerializer, sal_Int32 elementT
// compare the properties with the theme properties before writing them:
// if they are equal, it means that they were style-defined and there is
// no need to write them.
- if( rStyleProps != nullptr && pBorderLine && !pBorderLine->isEmpty() &&
- pBorderLine->GetBorderLineStyle() == static_cast<SvxBorderLineStyle>(rStyleProps->LineStyle) &&
- pBorderLine->GetColor() == Color(ColorTransparency, rStyleProps->Color) &&
- pBorderLine->GetWidth() == o3tl::toTwips(rStyleProps->LineWidth, o3tl::Length::mm100) )
+ if (pStyleProps && pBorderLine && !pBorderLine->isEmpty()
+ && pBorderLine->GetBorderLineStyle()
+ == static_cast<SvxBorderLineStyle>(pStyleProps->LineStyle)
+ && pBorderLine->GetColor() == Color(ColorTransparency, pStyleProps->Color)
+ && pBorderLine->GetWidth() == o3tl::toTwips(pStyleProps->LineWidth, o3tl::Length::mm100))
+ {
return;
+ }
rtl::Reference<FastAttributeList> pAttr = FastSerializerHelper::createAttrList();
pAttr->add( FSNS( XML_w, XML_val ), pVal );