diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2016-09-15 12:43:01 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2016-09-15 13:02:24 +0200 |
commit | 27be81819064cb96d98c881f45d6e3fbdf7a33d0 (patch) | |
tree | f182a2979a2c0df28f21c1fa0634d56bc772500f /lotuswordpro/source | |
parent | f7ae11ce60c0d1d63e09041e621f9e95bb952847 (diff) |
loplugin:singlevalfields in l10ntools..sax
and ignore URE headers in the plugin
Change-Id: I939df744c1173cf0f67d515f6c3fb4ac4cb25588
Diffstat (limited to 'lotuswordpro/source')
38 files changed, 35 insertions, 185 deletions
diff --git a/lotuswordpro/source/filter/bento.hxx b/lotuswordpro/source/filter/bento.hxx index 1870c97af679..96e67145532d 100644 --- a/lotuswordpro/source/filter/bento.hxx +++ b/lotuswordpro/source/filter/bento.hxx @@ -265,7 +265,6 @@ public: // Internal methods explicit CBenValue(BenObjectID TypeID):CBenIDListElmt(TypeID) { cpProperty = nullptr; - cpReferencedList = nullptr; } void SetProperty(pCBenProperty pProperty) @@ -281,7 +280,6 @@ public: // Internal methods private: // Data pCBenProperty cpProperty; CUtOwningList cValueSegments; - pCBenValue cpReferencedList; }; class CBenProperty : public CBenIDListElmt diff --git a/lotuswordpro/source/filter/localtime.cxx b/lotuswordpro/source/filter/localtime.cxx index d6be85751b3b..c243a36c07c0 100644 --- a/lotuswordpro/source/filter/localtime.cxx +++ b/lotuswordpro/source/filter/localtime.cxx @@ -158,8 +158,6 @@ bool LtgGmTime(long rtime,LtTm& rtm) rtm.tm_min = (long)(caltim / 60); rtm.tm_sec = (long)(caltim - (rtm.tm_min) * 60); - rtm.tm_isdst = 0; - //adjust year & month rtm.tm_year += 1900; ++(rtm.tm_mon); diff --git a/lotuswordpro/source/filter/localtime.hxx b/lotuswordpro/source/filter/localtime.hxx index a861325e7c12..67784ca7dbcb 100644 --- a/lotuswordpro/source/filter/localtime.hxx +++ b/lotuswordpro/source/filter/localtime.hxx @@ -66,7 +66,6 @@ struct LtTm long tm_year; /* years since 1900 */ long tm_wday; /* days since Sunday - [0,6] */ long tm_yday; /* days since January 1 - [0,365] */ - long tm_isdst; /* daylight savings time flag */ LtTm() : tm_sec(0) , tm_min(0) @@ -76,7 +75,6 @@ struct LtTm , tm_year(0) , tm_wday(0) , tm_yday(0) - , tm_isdst(0) { } }; diff --git a/lotuswordpro/source/filter/lwpbulletstylemgr.cxx b/lotuswordpro/source/filter/lwpbulletstylemgr.cxx index 358655a9f8ad..5bc408a29e64 100644 --- a/lotuswordpro/source/filter/lwpbulletstylemgr.cxx +++ b/lotuswordpro/source/filter/lwpbulletstylemgr.cxx @@ -73,7 +73,6 @@ LwpBulletStyleMgr::LwpBulletStyleMgr() : m_pFoundry(nullptr) - , m_pBulletList(nullptr) , m_bContinue(true) , m_bIsBulletSkipped(false) { @@ -81,11 +80,6 @@ LwpBulletStyleMgr::LwpBulletStyleMgr() LwpBulletStyleMgr::~LwpBulletStyleMgr() { - if (m_pBulletList) - { - delete m_pBulletList; - } - m_vIDsPairList.clear(); m_vStyleNameList.clear(); } diff --git a/lotuswordpro/source/filter/lwpbulletstylemgr.hxx b/lotuswordpro/source/filter/lwpbulletstylemgr.hxx index 878b2c35c871..cfcb0a92a93c 100644 --- a/lotuswordpro/source/filter/lwpbulletstylemgr.hxx +++ b/lotuswordpro/source/filter/lwpbulletstylemgr.hxx @@ -93,7 +93,6 @@ private: std::vector <OUString> m_vStyleNameList; std::vector <OverridePair> m_vIDsPairList; LwpFoundry* m_pFoundry; - XFList* m_pBulletList; bool m_bContinue; bool m_bIsBulletSkipped; LwpObjectID m_aCurrentNumberingID; diff --git a/lotuswordpro/source/filter/lwppara.hxx b/lotuswordpro/source/filter/lwppara.hxx index fd61f1922152..16cdc49c4a8b 100644 --- a/lotuswordpro/source/filter/lwppara.hxx +++ b/lotuswordpro/source/filter/lwppara.hxx @@ -119,9 +119,7 @@ struct ParaNumbering LwpFribParaNumber* pParaNumber; LwpFribText* pSuffix; - sal_uInt16 nPrefixLevel;//hidelevels of prefix text frib sal_uInt16 nNumLevel;//hidelevels of paranumber frib - sal_uInt16 nSuffixLevel;//hidelevels of suffix text frib ParaNumbering() { @@ -133,9 +131,7 @@ struct ParaNumbering pPrefix = nullptr; pParaNumber = nullptr; pSuffix = nullptr; - nPrefixLevel = 0; nNumLevel = 0; - nSuffixLevel = 0; } }; diff --git a/lotuswordpro/source/filter/xfilter/xfdate.cxx b/lotuswordpro/source/filter/xfilter/xfdate.cxx index 3236602fde0f..791c3c805367 100644 --- a/lotuswordpro/source/filter/xfilter/xfdate.cxx +++ b/lotuswordpro/source/filter/xfilter/xfdate.cxx @@ -62,8 +62,6 @@ XFDate::XFDate() { - m_bFixed = false; - m_bValued = false; } XFDate::~XFDate() @@ -77,11 +75,6 @@ void XFDate::ToXml(IXFStream *pStrm) pAttrList->Clear(); if( !GetStyleName().isEmpty() ) pAttrList->AddAttribute( "style:data-style-name", GetStyleName() ); - if (m_bValued) - pAttrList->AddAttribute( "text:date-value", m_strDate ); - - if( m_bFixed ) - pAttrList->AddAttribute( "text:fixed", "true" ); pStrm->StartElement( "text:date" ); if (!m_strText.isEmpty()) diff --git a/lotuswordpro/source/filter/xfilter/xfdate.hxx b/lotuswordpro/source/filter/xfilter/xfdate.hxx index 1c2c9d365700..daeb2654e7e9 100644 --- a/lotuswordpro/source/filter/xfilter/xfdate.hxx +++ b/lotuswordpro/source/filter/xfilter/xfdate.hxx @@ -76,10 +76,8 @@ public: virtual void ToXml(IXFStream *pStrm) override; private: - bool m_bFixed; OUString m_strText; OUString m_strDate; - bool m_bValued; }; class XFDateStart : public XFDate diff --git a/lotuswordpro/source/filter/xfilter/xfdatestyle.cxx b/lotuswordpro/source/filter/xfilter/xfdatestyle.cxx index bdd1d15419c0..27df1203831c 100644 --- a/lotuswordpro/source/filter/xfilter/xfdatestyle.cxx +++ b/lotuswordpro/source/filter/xfilter/xfdatestyle.cxx @@ -159,8 +159,6 @@ void XFDatePart::ToXml(IXFStream *pStrm) XFDateStyle::XFDateStyle() { - m_bFixed = false; - m_bAutoOrder = false; } XFDateStyle::~XFDateStyle() diff --git a/lotuswordpro/source/filter/xfilter/xfdatestyle.hxx b/lotuswordpro/source/filter/xfilter/xfdatestyle.hxx index 4250bd0171d9..bacf9ee5ac95 100644 --- a/lotuswordpro/source/filter/xfilter/xfdatestyle.hxx +++ b/lotuswordpro/source/filter/xfilter/xfdatestyle.hxx @@ -112,8 +112,6 @@ public: virtual void ToXml(IXFStream *pStrm) override; private: - bool m_bFixed; - bool m_bAutoOrder; XFStyleContainer m_aParts; }; diff --git a/lotuswordpro/source/filter/xfilter/xfdrawline.cxx b/lotuswordpro/source/filter/xfilter/xfdrawline.cxx index cfdc590c4f21..a5ea983faafa 100644 --- a/lotuswordpro/source/filter/xfilter/xfdrawline.cxx +++ b/lotuswordpro/source/filter/xfilter/xfdrawline.cxx @@ -108,9 +108,9 @@ void XFDrawLine::ToXml(IXFStream *pStrm) if( m_nFlag&XFDRAWOBJECT_FLAG_TRANLATE ) strTransform += "translate (" + OUString::number(m_aRotatePoint.GetX()) + "cm " + OUString::number(m_aRotatePoint.GetY()) + "cm) "; if( m_nFlag&XFDRAWOBJECT_FLAG_SKEWX ) - strTransform += "skewX (" + OUString::number(m_fSkewX) + " "; + strTransform += "skewX (" + OUString::number(0) + " "; if( m_nFlag&XFDRAWOBJECT_FLAG_SKEWY ) - strTransform += "skewY (" + OUString::number(m_fSkewY) + " "; + strTransform += "skewY (" + OUString::number(0) + " "; strTransform = strTransform.trim(); if( !strTransform.isEmpty() ) diff --git a/lotuswordpro/source/filter/xfilter/xfdrawobj.cxx b/lotuswordpro/source/filter/xfilter/xfdrawobj.cxx index c66391360480..bdfa5a4f8139 100644 --- a/lotuswordpro/source/filter/xfilter/xfdrawobj.cxx +++ b/lotuswordpro/source/filter/xfilter/xfdrawobj.cxx @@ -62,10 +62,6 @@ XFDrawObject::XFDrawObject() { m_fRotate = 0; - m_fScaleX = 0; - m_fScaleY = 0; - m_fSkewX = 0; - m_fSkewY = 0; m_nFlag = 0; m_eType = enumXFFrameDrawing; } @@ -120,11 +116,11 @@ void XFDrawObject::ToXml(IXFStream *pStrm) if( m_nFlag&XFDRAWOBJECT_FLAG_TRANLATE ) strTransform += "translate (" + OUString::number(m_aRotatePoint.GetX()) + "cm " + OUString::number(m_aRotatePoint.GetY()) + "cm) "; if( m_nFlag&XFDRAWOBJECT_FLAG_SCALE ) - strTransform += "scale (" + OUString::number(m_fScaleX) + "cm " + OUString::number(m_fScaleY) + "cm) "; + strTransform += "scale (" + OUString::number(0) + "cm " + OUString::number(0) + "cm) "; if( m_nFlag&XFDRAWOBJECT_FLAG_SKEWX ) - strTransform += "skewX (" + OUString::number(m_fSkewX) + " "; + strTransform += "skewX (" + OUString::number(0) + " "; if( m_nFlag&XFDRAWOBJECT_FLAG_SKEWY ) - strTransform += "skewY (" + OUString::number(m_fSkewY) + " "; + strTransform += "skewY (" + OUString::number(0) + " "; strTransform = strTransform.trim(); if( !strTransform.isEmpty() ) diff --git a/lotuswordpro/source/filter/xfilter/xfdrawobj.hxx b/lotuswordpro/source/filter/xfilter/xfdrawobj.hxx index 4d19489b64a9..3c4292acac7f 100644 --- a/lotuswordpro/source/filter/xfilter/xfdrawobj.hxx +++ b/lotuswordpro/source/filter/xfilter/xfdrawobj.hxx @@ -100,10 +100,6 @@ public: protected: double m_fRotate; XFPoint m_aRotatePoint; - double m_fScaleX; - double m_fScaleY; - double m_fSkewX; - double m_fSkewY; unsigned int m_nFlag; }; diff --git a/lotuswordpro/source/filter/xfilter/xfdrawrect.cxx b/lotuswordpro/source/filter/xfilter/xfdrawrect.cxx index 21e073756845..05a3bf13f52c 100644 --- a/lotuswordpro/source/filter/xfilter/xfdrawrect.cxx +++ b/lotuswordpro/source/filter/xfilter/xfdrawrect.cxx @@ -61,7 +61,6 @@ XFDrawRect::XFDrawRect() { - m_fCornerRadius = 0; } void XFDrawRect::ToXml(IXFStream *pStrm) @@ -70,8 +69,6 @@ void XFDrawRect::ToXml(IXFStream *pStrm) pAttrList->Clear(); - if( 0 != m_fCornerRadius ) - pAttrList->AddAttribute( "draw:corner-radius", OUString::number(m_fCornerRadius) + "cm" ); XFDrawObject::ToXml(pStrm); pStrm->StartElement( "draw:rect" ); diff --git a/lotuswordpro/source/filter/xfilter/xfdrawrect.hxx b/lotuswordpro/source/filter/xfilter/xfdrawrect.hxx index 1f7fabe5c06c..412b51f7405a 100644 --- a/lotuswordpro/source/filter/xfilter/xfdrawrect.hxx +++ b/lotuswordpro/source/filter/xfilter/xfdrawrect.hxx @@ -76,9 +76,6 @@ public: void SetSize(double width, double height); virtual void ToXml(IXFStream *pStrm) override; - -private: - double m_fCornerRadius; }; inline void XFDrawRect::SetSize(double width, double height) diff --git a/lotuswordpro/source/filter/xfilter/xfentry.cxx b/lotuswordpro/source/filter/xfilter/xfentry.cxx index 4d34c112fa8a..c4784e6a5bdc 100644 --- a/lotuswordpro/source/filter/xfilter/xfentry.cxx +++ b/lotuswordpro/source/filter/xfilter/xfentry.cxx @@ -66,7 +66,6 @@ XFEntry::XFEntry() : m_eType(enumXFEntryTOC) - , m_bMainEntry(false) , m_nOutlineLevel(1) {} @@ -90,9 +89,6 @@ void XFEntry::ToXml(IXFStream *pStrm) if( !m_strKey2.isEmpty() ) pAttrList->AddAttribute( "text:key2", m_strKey2 ); - if( m_bMainEntry ) - pAttrList->AddAttribute( "text:main-etry", "true" ); - pStrm->StartElement( "text:alphabetical-index-mark" ); // pStrm->Characters(m_strDisplay); pStrm->EndElement( "text:alphabetical-index-mark" ); diff --git a/lotuswordpro/source/filter/xfilter/xfentry.hxx b/lotuswordpro/source/filter/xfilter/xfentry.hxx index dc904f944b43..8195f42d0c2a 100644 --- a/lotuswordpro/source/filter/xfilter/xfentry.hxx +++ b/lotuswordpro/source/filter/xfilter/xfentry.hxx @@ -95,13 +95,12 @@ public: virtual void ToXml(IXFStream *pStrm) override; private: - enumXFEntry m_eType; - OUString m_strValue; - OUString m_strKey1; - OUString m_strKey2; - OUString m_strName; - bool m_bMainEntry; - sal_Int32 m_nOutlineLevel; + enumXFEntry m_eType; + OUString m_strValue; + OUString m_strKey1; + OUString m_strKey2; + OUString m_strName; + sal_Int32 m_nOutlineLevel; }; inline void XFEntry::SetEntryType(enumXFEntry type) diff --git a/lotuswordpro/source/filter/xfilter/xfframe.cxx b/lotuswordpro/source/filter/xfilter/xfframe.cxx index 4526f839829b..d34f56f484c3 100644 --- a/lotuswordpro/source/filter/xfilter/xfframe.cxx +++ b/lotuswordpro/source/filter/xfilter/xfframe.cxx @@ -71,7 +71,6 @@ XFFrame::XFFrame(bool isTextBox) , m_strName(XFGlobal::GenFrameName()) // give it a default name , m_nZIndex(ZINDEX_MIN) , m_fMinHeight(0) - , m_fMaxHeight(0) , m_eType(enumXFFrameTextbox) , m_nFlag(0) , m_isTextBox(isTextBox) @@ -163,7 +162,7 @@ void XFFrame::StartFrame(IXFStream *pStrm) { pAttrList->AddAttribute( "fo:min-height", OUString::number(m_fMinHeight) + "cm" ); if( m_nFlag&XFFRAME_FLAG_MAXHEIGHT ) - pAttrList->AddAttribute( "fo:max-height", OUString::number(m_fMaxHeight) + "cm" ); + pAttrList->AddAttribute( "fo:max-height", OUString::number(0) + "cm" ); } else pAttrList->AddAttribute( "svg:height", OUString::number(m_aRect.GetHeight()) + "cm" ); diff --git a/lotuswordpro/source/filter/xfilter/xfframe.hxx b/lotuswordpro/source/filter/xfilter/xfframe.hxx index 86125639439c..143635e9f728 100644 --- a/lotuswordpro/source/filter/xfilter/xfframe.hxx +++ b/lotuswordpro/source/filter/xfilter/xfframe.hxx @@ -176,12 +176,11 @@ private: protected: enumXFAnchor m_eAnchor; sal_Int32 m_nAnchorPage; - OUString m_strName; + OUString m_strName; sal_uInt32 m_nZIndex; XFRect m_aRect; double m_fMinHeight; - double m_fMaxHeight; - OUString m_strNextLink; + OUString m_strNextLink; enumXFFrameType m_eType; sal_uInt32 m_nFlag; bool m_isTextBox; diff --git a/lotuswordpro/source/filter/xfilter/xfframestyle.cxx b/lotuswordpro/source/filter/xfilter/xfframestyle.cxx index c73ae16fdb6d..82de4fbea14e 100644 --- a/lotuswordpro/source/filter/xfilter/xfframestyle.cxx +++ b/lotuswordpro/source/filter/xfilter/xfframestyle.cxx @@ -72,8 +72,6 @@ XFFrameStyle::XFFrameStyle() , m_bProtectContent(false) , m_bProtectSize(false) , m_bProtectPos(false) - , m_bPrintable(true) - , m_bBackground(false) , m_nTransparency(0) , m_eTextDir(enumXFTextDirNone) , m_eXPos(enumXFFrameXPosCenter) @@ -135,16 +133,7 @@ void XFFrameStyle::ToXml(IXFStream *pStrm) pAttrList->Clear(); - /*if( m_eWrap == enumXFWrapBackground ) - { - pAttrList->AddAttribute( "style:run-through", "background" ); - } - else - {*/ - if( m_bBackground) - pAttrList->AddAttribute( "style:run-through", "background" ); - else - pAttrList->AddAttribute( "style:run-through", "foreground" ); + pAttrList->AddAttribute( "style:run-through", "foreground" ); if( m_eWrap == enumXFWrapNone ) pAttrList->AddAttribute( "style:wrap", "none" ); @@ -179,8 +168,7 @@ void XFFrameStyle::ToXml(IXFStream *pStrm) if( m_pShadow ) m_pShadow->ToXml(pStrm); //print - if( m_bPrintable ) - pAttrList->AddAttribute( "style:print-content", "true" ); + pAttrList->AddAttribute( "style:print-content", "true" ); //text directory if( m_eTextDir != enumXFTextDirNone ) pAttrList->AddAttribute( "style:writing-mode", GetTextDirName(m_eTextDir) ); diff --git a/lotuswordpro/source/filter/xfilter/xfframestyle.hxx b/lotuswordpro/source/filter/xfilter/xfframestyle.hxx index 7dfda7c4cb40..d3ac67fc2121 100644 --- a/lotuswordpro/source/filter/xfilter/xfframestyle.hxx +++ b/lotuswordpro/source/filter/xfilter/xfframestyle.hxx @@ -156,12 +156,10 @@ protected: XFShadow *m_pShadow; XFBGImage *m_pBGImage; XFColor m_aBackColor; - bool m_bProtectContent; - bool m_bProtectSize; - bool m_bProtectPos; - bool m_bPrintable; - bool m_bBackground; - sal_Int16 m_nTransparency; + bool m_bProtectContent; + bool m_bProtectSize; + bool m_bProtectPos; + sal_Int16 m_nTransparency; enumXFTextDir m_eTextDir; enumXFFrameXPos m_eXPos; diff --git a/lotuswordpro/source/filter/xfilter/xfimagestyle.cxx b/lotuswordpro/source/filter/xfilter/xfimagestyle.cxx index 8f00dda4f122..b9adbb2fe79e 100644 --- a/lotuswordpro/source/filter/xfilter/xfimagestyle.cxx +++ b/lotuswordpro/source/filter/xfilter/xfimagestyle.cxx @@ -64,18 +64,11 @@ XFImageStyle::XFImageStyle() : m_nBrightness(0) , m_nContrast(0) - , m_nGamma(0) - , m_nTransparent(0) - , m_nAdjustRed(0) - , m_nAdjustGreen(0) - , m_nAdjustBlue(0) , m_fClipLeft(0) , m_fClipRight(0) , m_fClipTop(0) , m_fClipBottom(0) , m_bHoriFlip(false) - , m_bVertFlip(false) - , m_eColorMode(enumXFColorStandard) {} void XFImageStyle::ToXml(IXFStream *pStrm) @@ -123,34 +116,15 @@ void XFImageStyle::ToXml(IXFStream *pStrm) //margin: m_aMargins.ToXml(pStrm); //flip - if( m_bHoriFlip || m_bVertFlip ) - { - if( m_bHoriFlip && m_bVertFlip ) - pAttrList->AddAttribute( "style:mirror", "horizontal-on-right-pages vertical" ); - else if( m_bHoriFlip && !m_bVertFlip ) - pAttrList->AddAttribute( "style:mirror", "horizontal-on-right-pages" ); - else if( !m_bHoriFlip && m_bVertFlip ) - pAttrList->AddAttribute( "style:mirror", "vertical" ); - } - //color adjust - if( m_nAdjustRed ) - pAttrList->AddAttribute( "draw:red", OUString::number(m_nAdjustRed) + "%" ); - if( m_nAdjustGreen ) - pAttrList->AddAttribute( "draw:green", OUString::number(m_nAdjustGreen) + "%" ); - if( m_nAdjustBlue ) - pAttrList->AddAttribute( "draw:blue", OUString::number(m_nAdjustBlue) + "%" ); + if( m_bHoriFlip ) + pAttrList->AddAttribute( "style:mirror", "horizontal-on-right-pages" ); - if( m_nGamma ) - pAttrList->AddAttribute( "draw:gamma", OUString::number(m_nGamma) ); if( m_nBrightness ) pAttrList->AddAttribute( "draw:luminance", OUString::number(m_nBrightness) + "%" ); if( m_nContrast ) pAttrList->AddAttribute( "draw:contrast", OUString::number(m_nContrast) + "%" ); - if( m_nTransparent ) - pAttrList->AddAttribute( "draw:transparency", OUString::number(m_nTransparent) + "%" ); - - pAttrList->AddAttribute("draw:color-mode", GetColorMode(m_eColorMode)); + pAttrList->AddAttribute("draw:color-mode", GetColorMode(enumXFColorStandard)); //border if( m_pBorders ) m_pBorders->ToXml(pStrm); @@ -158,8 +132,7 @@ void XFImageStyle::ToXml(IXFStream *pStrm) if( m_pShadow ) m_pShadow->ToXml(pStrm); - if( m_bPrintable ) - pAttrList->AddAttribute( "style:print-content", "true" ); + pAttrList->AddAttribute( "style:print-content", "true" ); //protect: if( m_bProtectContent || m_bProtectSize || m_bProtectPos ) { diff --git a/lotuswordpro/source/filter/xfilter/xfimagestyle.hxx b/lotuswordpro/source/filter/xfilter/xfimagestyle.hxx index ea602e8dcbe8..02b898f819fb 100644 --- a/lotuswordpro/source/filter/xfilter/xfimagestyle.hxx +++ b/lotuswordpro/source/filter/xfilter/xfimagestyle.hxx @@ -80,18 +80,11 @@ public: private: sal_Int32 m_nBrightness; sal_Int32 m_nContrast; - sal_Int32 m_nGamma; - sal_Int32 m_nTransparent; - sal_Int32 m_nAdjustRed; - sal_Int32 m_nAdjustGreen; - sal_Int32 m_nAdjustBlue; double m_fClipLeft; double m_fClipRight; double m_fClipTop; double m_fClipBottom; - bool m_bHoriFlip; - bool m_bVertFlip; - enumXFColorMode m_eColorMode; + bool m_bHoriFlip; }; inline void XFImageStyle::SetBrightness(sal_Int32 brightness) diff --git a/lotuswordpro/source/filter/xfilter/xfindex.cxx b/lotuswordpro/source/filter/xfilter/xfindex.cxx index dc1011d29701..ebde5543f910 100644 --- a/lotuswordpro/source/filter/xfilter/xfindex.cxx +++ b/lotuswordpro/source/filter/xfilter/xfindex.cxx @@ -64,13 +64,10 @@ XFIndex::XFIndex() : m_eType(enumXFIndexTOC) , m_bProtect(true) , m_bSeparator(false) - , m_pTitle(nullptr) {} XFIndex::~XFIndex() { - delete m_pTitle; - while(m_aTemplates.size()>0) { XFIndexTemplate * pTemplate = m_aTemplates.back(); @@ -230,8 +227,6 @@ void XFIndex::ToXml(IXFStream *pStrm) { pAttrList->AddAttribute( "text:name", m_strTitle + "_Head" ); pStrm->StartElement( "text:index-title" ); - if( m_pTitle ) - m_pTitle->ToXml(pStrm); pStrm->EndElement( "text:index-title" ); } diff --git a/lotuswordpro/source/filter/xfilter/xfindex.hxx b/lotuswordpro/source/filter/xfilter/xfindex.hxx index e68c03497155..9f32e464c833 100644 --- a/lotuswordpro/source/filter/xfilter/xfindex.hxx +++ b/lotuswordpro/source/filter/xfilter/xfindex.hxx @@ -167,7 +167,6 @@ private: OUString m_strTitle; bool m_bProtect; bool m_bSeparator; - XFParagraph* m_pTitle; std::vector<XFIndexTemplate *> m_aTemplates; // template entry + style diff --git a/lotuswordpro/source/filter/xfilter/xflinenumberconfig.hxx b/lotuswordpro/source/filter/xfilter/xflinenumberconfig.hxx index 1b6e6386a828..6d9a7cac5a9a 100644 --- a/lotuswordpro/source/filter/xfilter/xflinenumberconfig.hxx +++ b/lotuswordpro/source/filter/xfilter/xflinenumberconfig.hxx @@ -82,25 +82,22 @@ public: private: enumXFLineNumberPos m_ePosition; - double m_fOffset; - sal_Int32 m_nIncrement; - sal_Int32 m_nSepIncrement; + double m_fOffset; + sal_Int32 m_nIncrement; + static const sal_Int32 m_nSepIncrement = 3; OUString m_strSeparator; OUString m_strNumFmt; OUString m_strTextStyle; - bool m_bRestartOnPage; - bool m_bCountEmptyLines; - bool m_bCountFrameLines; + bool m_bRestartOnPage; + bool m_bCountEmptyLines; }; inline XFLineNumberConfig::XFLineNumberConfig() : m_ePosition(enumXFLineNumberLeft) , m_fOffset(0) , m_nIncrement(5) - , m_nSepIncrement(3) , m_bRestartOnPage(false) , m_bCountEmptyLines(true) - , m_bCountFrameLines(false) {} inline void XFLineNumberConfig::SetNumberOffset(double offset) @@ -158,10 +155,7 @@ inline void XFLineNumberConfig::ToXml(IXFStream *pStrm) else pAttrList->AddAttribute( "text:count-empty-lines", "false" ); - if( m_bCountFrameLines ) - pAttrList->AddAttribute( "text:count-in-floating-frames", "true" ); - else - pAttrList->AddAttribute( "text:count-in-floating-frames", "false" ); + pAttrList->AddAttribute( "text:count-in-floating-frames", "false" ); pStrm->StartElement( "text:linenumbering-configuration" ); diff --git a/lotuswordpro/source/filter/xfilter/xflist.cxx b/lotuswordpro/source/filter/xfilter/xflist.cxx index 24980edafac5..7a270edafcec 100644 --- a/lotuswordpro/source/filter/xfilter/xflist.cxx +++ b/lotuswordpro/source/filter/xfilter/xflist.cxx @@ -66,7 +66,6 @@ XFList::XFList() { m_bOrdered = true; m_bContinueNumber = false; - m_pHeader = nullptr; } XFList::~XFList() @@ -89,10 +88,6 @@ void XFList::ToXml(IXFStream *pStrm) else pStrm->StartElement( "text:unordered-list" ); - if( m_pHeader ) - { - m_pHeader->ToXml(pStrm); - } XFContentContainer::ToXml(pStrm); if( m_bOrdered ) diff --git a/lotuswordpro/source/filter/xfilter/xflist.hxx b/lotuswordpro/source/filter/xfilter/xflist.hxx index 5dee764803df..547021a98145 100644 --- a/lotuswordpro/source/filter/xfilter/xflist.hxx +++ b/lotuswordpro/source/filter/xfilter/xflist.hxx @@ -95,8 +95,6 @@ public: private: bool m_bOrdered; bool m_bContinueNumber; - XFListItem *m_pHeader; - }; inline void XFList::SetOrdered(bool ordered) diff --git a/lotuswordpro/source/filter/xfilter/xfpagemaster.cxx b/lotuswordpro/source/filter/xfilter/xfpagemaster.cxx index e22d6f19fb23..90d5009680b6 100644 --- a/lotuswordpro/source/filter/xfilter/xfpagemaster.cxx +++ b/lotuswordpro/source/filter/xfilter/xfpagemaster.cxx @@ -69,7 +69,7 @@ #include "xfbgimage.hxx" XFPageMaster::XFPageMaster() : m_fPageWidth(0), m_fPageHeight(0), m_eUsage(enumXFPageUsageNone), -m_eTextDir(enumXFTextDirNone), m_bPrintOrient(true), m_pBorders(nullptr), m_pShadow(nullptr), +m_eTextDir(enumXFTextDirNone), m_pBorders(nullptr), m_pShadow(nullptr), m_pColumns(nullptr), m_pBGImage(nullptr), m_pHeaderStyle(nullptr), m_pFooterStyle(nullptr), m_eSepAlign(enumXFAlignNone), m_fSepWidth(0), m_aSepColor(0), m_fSepSpaceAbove(0), m_fSepSpaceBelow(0), m_nSepLengthPercent(0) @@ -219,10 +219,7 @@ void XFPageMaster::ToXml(IXFStream *pStream) m_aMargin.ToXml(pStream); - if( m_bPrintOrient ) - pAttrList->AddAttribute( "style:print-orientation", "portrait" ); - else - pAttrList->AddAttribute( "style:print-orientation", "landscape" ); + pAttrList->AddAttribute( "style:print-orientation", "portrait" ); if( m_pBorders ) m_pBorders->ToXml(pStream); diff --git a/lotuswordpro/source/filter/xfilter/xfpagemaster.hxx b/lotuswordpro/source/filter/xfilter/xfpagemaster.hxx index 584c162ce4b5..a6e9fb5eb11b 100644 --- a/lotuswordpro/source/filter/xfilter/xfpagemaster.hxx +++ b/lotuswordpro/source/filter/xfilter/xfpagemaster.hxx @@ -125,7 +125,6 @@ private: enumXFPageUsage m_eUsage; enumXFTextDir m_eTextDir; - bool m_bPrintOrient; XFBorders *m_pBorders; XFShadow *m_pShadow; diff --git a/lotuswordpro/source/filter/xfilter/xfrowstyle.cxx b/lotuswordpro/source/filter/xfilter/xfrowstyle.cxx index 460ba39ef786..3f576b51ef0b 100644 --- a/lotuswordpro/source/filter/xfilter/xfrowstyle.cxx +++ b/lotuswordpro/source/filter/xfilter/xfrowstyle.cxx @@ -64,7 +64,6 @@ XFRowStyle::XFRowStyle():m_fHeight(0) { m_fHeight = 0; m_fMinHeight = 0; - m_pBGImage = nullptr; } enumXFStyle XFRowStyle::GetStyleFamily() @@ -90,11 +89,9 @@ void XFRowStyle::ToXml(IXFStream *pStrm) else if( m_fHeight ) pAttrList->AddAttribute( "style:row-height", OUString::number(m_fHeight) + "cm" ); - if( m_aBackColor.IsValid() && !m_pBGImage ) + if( m_aBackColor.IsValid() ) pAttrList->AddAttribute( "fo:background-color", m_aBackColor.ToString() ); pStrm->StartElement( "style:properties" ); - if( m_pBGImage ) - m_pBGImage->ToXml(pStrm); pStrm->EndElement( "style:properties" ); pStrm->EndElement( "style:style" ); @@ -107,13 +104,6 @@ XFRowStyle& XFRowStyle::operator=(XFRowStyle const &other) m_fHeight = other.m_fHeight; m_fMinHeight = other.m_fMinHeight; m_aBackColor = other.m_aBackColor; - - delete m_pBGImage; - - if( other.m_pBGImage ) - m_pBGImage = new XFBGImage(*other.m_pBGImage); - else - m_pBGImage = nullptr; } return *this; } diff --git a/lotuswordpro/source/filter/xfilter/xfrowstyle.hxx b/lotuswordpro/source/filter/xfilter/xfrowstyle.hxx index 0d048917b80e..8f2c3871171f 100644 --- a/lotuswordpro/source/filter/xfilter/xfrowstyle.hxx +++ b/lotuswordpro/source/filter/xfilter/xfrowstyle.hxx @@ -86,7 +86,6 @@ private: double m_fHeight; double m_fMinHeight; XFColor m_aBackColor; - XFBGImage *m_pBGImage; }; inline void XFRowStyle::SetRowHeight(double height) diff --git a/lotuswordpro/source/filter/xfilter/xfsection.cxx b/lotuswordpro/source/filter/xfilter/xfsection.cxx index 2b9c7c9b9774..5079fe7936ea 100644 --- a/lotuswordpro/source/filter/xfilter/xfsection.cxx +++ b/lotuswordpro/source/filter/xfilter/xfsection.cxx @@ -61,8 +61,6 @@ XFSection::XFSection() { - m_bProtected = false; - m_bHiden = false; m_strSectionName = XFGlobal::GenSectionName(); } @@ -83,10 +81,6 @@ void XFSection::ToXml(IXFStream *pStrm) //section name if( !m_strSectionName.isEmpty() ) pAttrList->AddAttribute( "text:name", m_strSectionName); - if( m_bProtected ) - pAttrList->AddAttribute( "text:protected", "true" ); - if( m_bHiden ) - pAttrList->AddAttribute( "text:display", "none" ); pStrm->StartElement( "text:section" ); if( !m_strSourceLink.isEmpty() ) diff --git a/lotuswordpro/source/filter/xfilter/xfsection.hxx b/lotuswordpro/source/filter/xfilter/xfsection.hxx index 1b892864c929..b17b4ae2a513 100644 --- a/lotuswordpro/source/filter/xfilter/xfsection.hxx +++ b/lotuswordpro/source/filter/xfilter/xfsection.hxx @@ -76,8 +76,6 @@ public: virtual ~XFSection() override; -public: - /** * @descr Output section object. */ @@ -85,8 +83,6 @@ public: private: OUString m_strSectionName; - bool m_bProtected; - bool m_bHiden; OUString m_strSourceLink; }; diff --git a/lotuswordpro/source/filter/xfilter/xfsectionstyle.cxx b/lotuswordpro/source/filter/xfilter/xfsectionstyle.cxx index 1db64ed1ae41..89f968eb26b4 100644 --- a/lotuswordpro/source/filter/xfilter/xfsectionstyle.cxx +++ b/lotuswordpro/source/filter/xfilter/xfsectionstyle.cxx @@ -64,14 +64,12 @@ XFSectionStyle::XFSectionStyle() { m_fMarginLeft = 0; m_fMarginRight = 0; - m_pBackImage = nullptr; m_pColumns = nullptr; } XFSectionStyle::~XFSectionStyle() { delete m_pColumns; - delete m_pBackImage; } enumXFStyle XFSectionStyle::GetStyleFamily() @@ -114,7 +112,7 @@ void XFSectionStyle::ToXml(IXFStream *pStrm) { pAttrList->AddAttribute( "fo:margin-right", OUString::number(m_fMarginRight) + "cm" ); } - if( m_aBackColor.IsValid() && !m_pBackImage ) + if( m_aBackColor.IsValid() ) { pAttrList->AddAttribute( "fo:background-color", m_aBackColor.ToString() ); } @@ -127,8 +125,6 @@ void XFSectionStyle::ToXml(IXFStream *pStrm) if( m_pColumns ) m_pColumns->ToXml(pStrm); - if( m_pBackImage ) - m_pBackImage->ToXml(pStrm); pStrm->EndElement( "style:properties" ); diff --git a/lotuswordpro/source/filter/xfilter/xfsectionstyle.hxx b/lotuswordpro/source/filter/xfilter/xfsectionstyle.hxx index 78c2ad77e2fd..af0a88c2c2e6 100644 --- a/lotuswordpro/source/filter/xfilter/xfsectionstyle.hxx +++ b/lotuswordpro/source/filter/xfilter/xfsectionstyle.hxx @@ -93,7 +93,6 @@ private: double m_fMarginRight; XFColor m_aBackColor; XFColumns *m_pColumns; - XFBGImage *m_pBackImage; }; #endif diff --git a/lotuswordpro/source/filter/xfilter/xftimestyle.cxx b/lotuswordpro/source/filter/xfilter/xftimestyle.cxx index 73072df04513..d36266ec01fb 100644 --- a/lotuswordpro/source/filter/xfilter/xftimestyle.cxx +++ b/lotuswordpro/source/filter/xfilter/xftimestyle.cxx @@ -108,7 +108,6 @@ void XFTimePart::ToXml(IXFStream *pStrm) XFTimeStyle::XFTimeStyle() { - m_bFixed = true; m_bAmPm = false; m_bTruncate = true; } diff --git a/lotuswordpro/source/filter/xfilter/xftimestyle.hxx b/lotuswordpro/source/filter/xfilter/xftimestyle.hxx index f9b4d6a8416c..521aa2ba20be 100644 --- a/lotuswordpro/source/filter/xfilter/xftimestyle.hxx +++ b/lotuswordpro/source/filter/xfilter/xftimestyle.hxx @@ -127,7 +127,6 @@ public: void SetTruncate(bool bTrunc); private: - bool m_bFixed; bool m_bAmPm; std::vector<XFTimePart> m_aParts; bool m_bTruncate; |