diff options
author | Noel Grandin <noel@peralex.com> | 2016-04-27 09:22:13 +0200 |
---|---|---|
committer | Noel Grandin <noelgrandin@gmail.com> | 2016-04-28 09:31:16 +0000 |
commit | 43b4903db3e925c652e25c34362490f8adc9c5ec (patch) | |
tree | af12777b72d42280467e8cc19b914b2c7f4f3816 /xmloff | |
parent | 7d6308dad9f4a079d57719a6e3a9c4cebb47d051 (diff) |
teach stylepolice plugin about ref-counted-pointer naming
Change-Id: I6e91d22fc1826038c05ddb6fc065563c6a250752
Reviewed-on: https://gerrit.libreoffice.org/24459
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'xmloff')
-rw-r--r-- | xmloff/source/draw/sdxmlexp.cxx | 8 | ||||
-rw-r--r-- | xmloff/source/draw/shapeexport.cxx | 66 | ||||
-rw-r--r-- | xmloff/source/draw/ximp3dobject.cxx | 6 | ||||
-rw-r--r-- | xmloff/source/draw/ximp3dscene.cxx | 10 | ||||
-rw-r--r-- | xmloff/source/style/XMLPageExport.cxx | 14 | ||||
-rw-r--r-- | xmloff/source/style/styleexp.cxx | 8 | ||||
-rw-r--r-- | xmloff/source/table/XMLTableExport.cxx | 18 | ||||
-rw-r--r-- | xmloff/source/text/txtparae.cxx | 56 |
8 files changed, 93 insertions, 93 deletions
diff --git a/xmloff/source/draw/sdxmlexp.cxx b/xmloff/source/draw/sdxmlexp.cxx index 03586a0a73fb..80f18e17095d 100644 --- a/xmloff/source/draw/sdxmlexp.cxx +++ b/xmloff/source/draw/sdxmlexp.cxx @@ -1653,18 +1653,18 @@ OUString SdXMLExport::ImpCreatePresPageStyleName( const Reference<XDrawPage>& xD const rtl::Reference< SvXMLExportPropertyMapper > aMapperRef( GetPresPagePropsMapper() ); - std::vector< XMLPropertyState > xPropStates( aMapperRef->Filter( xPropSet ) ); + std::vector< XMLPropertyState > aPropStates( aMapperRef->Filter( xPropSet ) ); - if( !xPropStates.empty() ) + if( !aPropStates.empty() ) { // there are filtered properties -> hard attributes // try to find this style in AutoStylePool - sStyleName = GetAutoStylePool()->Find(XML_STYLE_FAMILY_SD_DRAWINGPAGE_ID, sStyleName, xPropStates); + sStyleName = GetAutoStylePool()->Find(XML_STYLE_FAMILY_SD_DRAWINGPAGE_ID, sStyleName, aPropStates); if(sStyleName.isEmpty()) { // Style did not exist, add it to AutoStalePool - sStyleName = GetAutoStylePool()->Add(XML_STYLE_FAMILY_SD_DRAWINGPAGE_ID, sStyleName, xPropStates); + sStyleName = GetAutoStylePool()->Add(XML_STYLE_FAMILY_SD_DRAWINGPAGE_ID, sStyleName, aPropStates); } } } diff --git a/xmloff/source/draw/shapeexport.cxx b/xmloff/source/draw/shapeexport.cxx index a305be733999..92c965ee0e71 100644 --- a/xmloff/source/draw/shapeexport.cxx +++ b/xmloff/source/draw/shapeexport.cxx @@ -377,12 +377,12 @@ void XMLShapeExport::collectShapeAutoStyles(const uno::Reference< drawing::XShap } // filter propset - std::vector< XMLPropertyState > xPropStates; + std::vector< XMLPropertyState > aPropStates; sal_Int32 nCount = 0; if( (!bIsEmptyPresObj || (aShapeInfo.meShapeType != XmlShapeTypePresPageShape)) ) { - xPropStates = GetPropertySetMapper()->Filter( xPropSet ); + aPropStates = GetPropertySetMapper()->Filter( xPropSet ); if (XmlShapeTypeDrawControlShape == aShapeInfo.meShapeType) { @@ -403,13 +403,13 @@ void XMLShapeExport::collectShapeAutoStyles(const uno::Reference< drawing::XShap DBG_ASSERT(-1 != nIndex, "XMLShapeExport::collectShapeAutoStyles: could not obtain the index for our context id!"); XMLPropertyState aNewState(nIndex, uno::makeAny(sNumberStyle)); - xPropStates.push_back(aNewState); + aPropStates.push_back(aNewState); } } } - std::vector< XMLPropertyState >::iterator aIter = xPropStates.begin(); - std::vector< XMLPropertyState >::iterator aEnd = xPropStates.end(); + std::vector< XMLPropertyState >::iterator aIter = aPropStates.begin(); + std::vector< XMLPropertyState >::iterator aEnd = aPropStates.end(); while( aIter != aEnd ) { if( aIter->mnIndex != -1 ) @@ -427,19 +427,19 @@ void XMLShapeExport::collectShapeAutoStyles(const uno::Reference< drawing::XShap { // there are filtered properties -> hard attributes // try to find this style in AutoStylePool - aShapeInfo.msStyleName = mrExport.GetAutoStylePool()->Find(aShapeInfo.mnFamily, aParentName, xPropStates); + aShapeInfo.msStyleName = mrExport.GetAutoStylePool()->Find(aShapeInfo.mnFamily, aParentName, aPropStates); if(aShapeInfo.msStyleName.isEmpty()) { // Style did not exist, add it to AutoStalePool - aShapeInfo.msStyleName = mrExport.GetAutoStylePool()->Add(aShapeInfo.mnFamily, aParentName, xPropStates); + aShapeInfo.msStyleName = mrExport.GetAutoStylePool()->Add(aShapeInfo.mnFamily, aParentName, aPropStates); } } // optionaly generate auto style for text attributes if( (!bIsEmptyPresObj || (aShapeInfo.meShapeType != XmlShapeTypePresPageShape)) && bObjSupportsText ) { - xPropStates = GetExport().GetTextParagraphExport()->GetParagraphPropertyMapper()->Filter( xPropSet ); + aPropStates = GetExport().GetTextParagraphExport()->GetParagraphPropertyMapper()->Filter( xPropSet ); // yet more additionally, we need to care for the ParaAdjust property if ( XmlShapeTypeDrawControlShape == aShapeInfo.meShapeType ) @@ -467,14 +467,14 @@ void XMLShapeExport::collectShapeAutoStyles(const uno::Reference< drawing::XShap uno::Any aParaAdjustValue = xPropSet->getPropertyValue( "ParaAdjust" ); XMLPropertyState aAlignDefaultState( nIndex, aParaAdjustValue ); - xPropStates.push_back( aAlignDefaultState ); + aPropStates.push_back( aAlignDefaultState ); } } } nCount = 0; - std::vector< XMLPropertyState >::iterator aIter = xPropStates.begin(); - std::vector< XMLPropertyState >::iterator aEnd = xPropStates.end(); + std::vector< XMLPropertyState >::iterator aIter = aPropStates.begin(); + std::vector< XMLPropertyState >::iterator aEnd = aPropStates.end(); while( aIter != aEnd ) { if( aIter->mnIndex != -1 ) @@ -484,11 +484,11 @@ void XMLShapeExport::collectShapeAutoStyles(const uno::Reference< drawing::XShap if( nCount ) { - aShapeInfo.msTextStyleName = mrExport.GetAutoStylePool()->Find( XML_STYLE_FAMILY_TEXT_PARAGRAPH, "", xPropStates ); + aShapeInfo.msTextStyleName = mrExport.GetAutoStylePool()->Find( XML_STYLE_FAMILY_TEXT_PARAGRAPH, "", aPropStates ); if(aShapeInfo.msTextStyleName.isEmpty()) { // Style did not exist, add it to AutoStalePool - aShapeInfo.msTextStyleName = mrExport.GetAutoStylePool()->Add(XML_STYLE_FAMILY_TEXT_PARAGRAPH, "", xPropStates); + aShapeInfo.msTextStyleName = mrExport.GetAutoStylePool()->Add(XML_STYLE_FAMILY_TEXT_PARAGRAPH, "", aPropStates); } } } @@ -3459,10 +3459,10 @@ void XMLShapeExport::ImpExport3DShape( // transformation (UNO_NAME_3D_TRANSFORM_MATRIX == "D3DTransformMatrix") uno::Any aAny = xPropSet->getPropertyValue("D3DTransformMatrix"); - drawing::HomogenMatrix xHomMat; - aAny >>= xHomMat; + drawing::HomogenMatrix aHomMat; + aAny >>= aHomMat; SdXMLImExTransform3D aTransform; - aTransform.AddHomogenMatrix(xHomMat); + aTransform.AddHomogenMatrix(aHomMat); if(aTransform.NeedsAction()) mrExport.AddAttribute(XML_NAMESPACE_DR3D, XML_TRANSFORM, aTransform.GetExportString(mrExport.GetMM100UnitConverter())); @@ -3550,13 +3550,13 @@ void XMLShapeExport::ImpExport3DShape( { // write special 3DLathe/3DExtrude attributes, get 3D tools::PolyPolygon as drawing::PolyPolygonShape3D aAny = xPropSet->getPropertyValue("D3DPolyPolygon3D"); - drawing::PolyPolygonShape3D xPolyPolygon3D; - aAny >>= xPolyPolygon3D; + drawing::PolyPolygonShape3D aUnoPolyPolygon3D; + aAny >>= aUnoPolyPolygon3D; // convert to 3D PolyPolygon const basegfx::B3DPolyPolygon aPolyPolygon3D( basegfx::tools::UnoPolyPolygonShape3DToB3DPolyPolygon( - xPolyPolygon3D)); + aUnoPolyPolygon3D)); // convert to 2D tools::PolyPolygon using identity 3D transformation (just grep X and Y) const basegfx::B3DHomMatrix aB3DHomMatrixFor2DConversion; @@ -3614,10 +3614,10 @@ void XMLShapeExport::export3DSceneAttributes( const css::uno::Reference< css::be // world transformation (UNO_NAME_3D_TRANSFORM_MATRIX == "D3DTransformMatrix") uno::Any aAny = xPropSet->getPropertyValue("D3DTransformMatrix"); - drawing::HomogenMatrix xHomMat; - aAny >>= xHomMat; + drawing::HomogenMatrix aHomMat; + aAny >>= aHomMat; SdXMLImExTransform3D aTransform; - aTransform.AddHomogenMatrix(xHomMat); + aTransform.AddHomogenMatrix(aHomMat); if(aTransform.NeedsAction()) mrExport.AddAttribute(XML_NAMESPACE_DR3D, XML_TRANSFORM, aTransform.GetExportString(mrExport.GetMM100UnitConverter())); @@ -3652,9 +3652,9 @@ void XMLShapeExport::export3DSceneAttributes( const css::uno::Reference< css::be // projection "D3DScenePerspective" drawing::ProjectionMode aAny = xPropSet->getPropertyValue("D3DScenePerspective"); - drawing::ProjectionMode xPrjMode; - aAny >>= xPrjMode; - if(xPrjMode == drawing::ProjectionMode_PARALLEL) + drawing::ProjectionMode aPrjMode; + aAny >>= aPrjMode; + if(aPrjMode == drawing::ProjectionMode_PARALLEL) aStr = GetXMLToken(XML_PARALLEL); else aStr = GetXMLToken(XML_PERSPECTIVE); @@ -3688,14 +3688,14 @@ void XMLShapeExport::export3DSceneAttributes( const css::uno::Reference< css::be // shadeMode aAny = xPropSet->getPropertyValue("D3DSceneShadeMode"); - drawing::ShadeMode xShadeMode; - if(aAny >>= xShadeMode) + drawing::ShadeMode aShadeMode; + if(aAny >>= aShadeMode) { - if(xShadeMode == drawing::ShadeMode_FLAT) + if(aShadeMode == drawing::ShadeMode_FLAT) aStr = GetXMLToken(XML_FLAT); - else if(xShadeMode == drawing::ShadeMode_PHONG) + else if(aShadeMode == drawing::ShadeMode_PHONG) aStr = GetXMLToken(XML_PHONG); - else if(xShadeMode == drawing::ShadeMode_SMOOTH) + else if(aShadeMode == drawing::ShadeMode_SMOOTH) aStr = GetXMLToken(XML_GOURAUD); else aStr = GetXMLToken(XML_DRAFT); @@ -3738,7 +3738,7 @@ void XMLShapeExport::export3DLamps( const css::uno::Reference< css::beans::XProp OUString aPropName; OUString aIndexStr; ::basegfx::B3DVector aLightDirection; - drawing::Direction3D xLightDir; + drawing::Direction3D aLightDir; bool bLightOnOff = false; for(sal_Int32 nLamp = 1; nLamp <= 8; nLamp++) { @@ -3756,8 +3756,8 @@ void XMLShapeExport::export3DLamps( const css::uno::Reference< css::beans::XProp // lightdirection aPropName = aDirectionPropName; aPropName += aIndexStr; - xPropSet->getPropertyValue(aPropName) >>= xLightDir; - aLightDirection = ::basegfx::B3DVector(xLightDir.DirectionX, xLightDir.DirectionY, xLightDir.DirectionZ); + xPropSet->getPropertyValue(aPropName) >>= aLightDir; + aLightDirection = ::basegfx::B3DVector(aLightDir.DirectionX, aLightDir.DirectionY, aLightDir.DirectionZ); SvXMLUnitConverter::convertB3DVector(sStringBuffer, aLightDirection); aStr = sStringBuffer.makeStringAndClear(); mrExport.AddAttribute(XML_NAMESPACE_DR3D, XML_DIRECTION, aStr); diff --git a/xmloff/source/draw/ximp3dobject.cxx b/xmloff/source/draw/ximp3dobject.cxx index e41fffcd5547..96eb4df63123 100644 --- a/xmloff/source/draw/ximp3dobject.cxx +++ b/xmloff/source/draw/ximp3dobject.cxx @@ -358,14 +358,14 @@ void SdXML3DPolygonBasedShapeContext::StartElement(const uno::Reference< xml::sa aPolyPolygon)); // convert to UNO API class PolyPolygonShape3D - drawing::PolyPolygonShape3D xPolyPolygon3D; + drawing::PolyPolygonShape3D aPolyPolygon3D; basegfx::tools::B3DPolyPolygonToUnoPolyPolygonShape3D( aB3DPolyPolygon, - xPolyPolygon3D); + aPolyPolygon3D); // set polygon data uno::Any aAny; - aAny <<= xPolyPolygon3D; + aAny <<= aPolyPolygon3D; xPropSet->setPropertyValue("D3DPolyPolygon3D", aAny); } else diff --git a/xmloff/source/draw/ximp3dscene.cxx b/xmloff/source/draw/ximp3dscene.cxx index 69fb32aef63f..666306d48dc3 100644 --- a/xmloff/source/draw/ximp3dscene.cxx +++ b/xmloff/source/draw/ximp3dscene.cxx @@ -392,11 +392,11 @@ void SdXML3DSceneAttributesHelper::setSceneAttributes( const css::uno::Reference // set anys aAny <<= pCtx->GetDiffuseColor(); - drawing::Direction3D xLightDir; - xLightDir.DirectionX = pCtx->GetDirection().getX(); - xLightDir.DirectionY = pCtx->GetDirection().getY(); - xLightDir.DirectionZ = pCtx->GetDirection().getZ(); - aAny2 <<= xLightDir; + drawing::Direction3D aLightDir; + aLightDir.DirectionX = pCtx->GetDirection().getX(); + aLightDir.DirectionY = pCtx->GetDirection().getY(); + aLightDir.DirectionZ = pCtx->GetDirection().getZ(); + aAny2 <<= aLightDir; aAny3 <<= pCtx->GetEnabled(); switch(a) diff --git a/xmloff/source/style/XMLPageExport.cxx b/xmloff/source/style/XMLPageExport.cxx index 5a3d4f5fec29..0d4f4061fa42 100644 --- a/xmloff/source/style/XMLPageExport.cxx +++ b/xmloff/source/style/XMLPageExport.cxx @@ -62,13 +62,13 @@ void XMLPageExport::collectPageMasterAutoStyle( DBG_ASSERT( xPageMasterPropSetMapper.is(), "page master family/XMLPageMasterPropSetMapper not found" ); if( xPageMasterPropSetMapper.is() ) { - ::std::vector<XMLPropertyState> xPropStates = xPageMasterExportPropMapper->Filter( rPropSet ); - if( !xPropStates.empty()) + ::std::vector<XMLPropertyState> aPropStates = xPageMasterExportPropMapper->Filter( rPropSet ); + if( !aPropStates.empty()) { OUString sParent; - rPageMasterName = rExport.GetAutoStylePool()->Find( XML_STYLE_FAMILY_PAGE_MASTER, sParent, xPropStates ); + rPageMasterName = rExport.GetAutoStylePool()->Find( XML_STYLE_FAMILY_PAGE_MASTER, sParent, aPropStates ); if (rPageMasterName.isEmpty()) - rPageMasterName = rExport.GetAutoStylePool()->Add(XML_STYLE_FAMILY_PAGE_MASTER, sParent, xPropStates); + rPageMasterName = rExport.GetAutoStylePool()->Add(XML_STYLE_FAMILY_PAGE_MASTER, sParent, aPropStates); } } } @@ -229,12 +229,12 @@ void XMLPageExport::exportDefaultStyle() // <style:default-style ...> GetExport().CheckAttrList(); - ::std::vector< XMLPropertyState > xPropStates = + ::std::vector< XMLPropertyState > aPropStates = xPageMasterExportPropMapper->FilterDefaults( xPropSet ); bool bExport = false; rtl::Reference < XMLPropertySetMapper > aPropMapper(xPageMasterExportPropMapper->getPropertySetMapper()); - for( ::std::vector< XMLPropertyState >::iterator aIter = xPropStates.begin(); aIter != xPropStates.end(); ++aIter ) + for( ::std::vector< XMLPropertyState >::iterator aIter = aPropStates.begin(); aIter != aPropStates.end(); ++aIter ) { XMLPropertyState *pProp = &(*aIter); sal_Int16 nContextId = aPropMapper->GetEntryContextId( pProp->mnIndex ); @@ -255,7 +255,7 @@ void XMLPageExport::exportDefaultStyle() XML_DEFAULT_PAGE_LAYOUT, true, true ); - xPageMasterExportPropMapper->exportXML( GetExport(), xPropStates, + xPageMasterExportPropMapper->exportXML( GetExport(), aPropStates, SvXmlExportFlags::IGN_WS ); } } diff --git a/xmloff/source/style/styleexp.cxx b/xmloff/source/style/styleexp.cxx index 0625ce210eb8..f96e1c78f188 100644 --- a/xmloff/source/style/styleexp.cxx +++ b/xmloff/source/style/styleexp.cxx @@ -314,14 +314,14 @@ bool XMLStyleExport::exportStyle( rPropMapper->SetStyleName( sName ); // <style:properties> - ::std::vector< XMLPropertyState > xPropStates = + ::std::vector< XMLPropertyState > aPropStates = rPropMapper->Filter( xPropSet, true ); bool const bUseExtensionNamespaceForGraphicProperties( rXMLFamily != "drawing-page" && rXMLFamily != "graphic" && rXMLFamily != "presentation" && rXMLFamily != "chart"); - rPropMapper->exportXML( GetExport(), xPropStates, + rPropMapper->exportXML( GetExport(), aPropStates, SvXmlExportFlags::IGN_WS, bUseExtensionNamespaceForGraphicProperties ); @@ -357,9 +357,9 @@ bool XMLStyleExport::exportDefaultStyle( XML_DEFAULT_STYLE, true, true ); // <style:properties> - ::std::vector< XMLPropertyState > xPropStates = + ::std::vector< XMLPropertyState > aPropStates = rPropMapper->FilterDefaults( xPropSet ); - rPropMapper->exportXML( GetExport(), xPropStates, + rPropMapper->exportXML( GetExport(), aPropStates, SvXmlExportFlags::IGN_WS ); } return true; diff --git a/xmloff/source/table/XMLTableExport.cxx b/xmloff/source/table/XMLTableExport.cxx index d8643b7bc3fc..1389f1e9f40a 100644 --- a/xmloff/source/table/XMLTableExport.cxx +++ b/xmloff/source/table/XMLTableExport.cxx @@ -210,11 +210,11 @@ static bool has_states( const std::vector< XMLPropertyState >& xPropStates ) for( sal_Int32 nColumn = 0; nColumn < nColumnCount; ++nColumn ) try { Reference< XPropertySet > xPropSet( xIndexAccessCols->getByIndex(nColumn) , UNO_QUERY_THROW ); - std::vector< XMLPropertyState > xPropStates( mxColumnExportPropertySetMapper->Filter( xPropSet ) ); + std::vector< XMLPropertyState > aPropStates( mxColumnExportPropertySetMapper->Filter( xPropSet ) ); - if( has_states( xPropStates ) ) + if( has_states( aPropStates ) ) { - const OUString sStyleName( mrExport.GetAutoStylePool()->Add(XML_STYLE_FAMILY_TABLE_COLUMN, xPropStates) ); + const OUString sStyleName( mrExport.GetAutoStylePool()->Add(XML_STYLE_FAMILY_TABLE_COLUMN, aPropStates) ); Reference< XInterface > xKey( xPropSet, UNO_QUERY ); xTableInfo->maColumnStyleMap[xKey] = sStyleName; } @@ -233,11 +233,11 @@ static bool has_states( const std::vector< XMLPropertyState >& xPropStates ) for( sal_Int32 nRow = 0; nRow < nRowCount; ++nRow ) try { Reference< XPropertySet > xPropSet( xIndexAccessRows->getByIndex(nRow) , UNO_QUERY_THROW ); - std::vector< XMLPropertyState > xRowPropStates( mxRowExportPropertySetMapper->Filter( xPropSet ) ); + std::vector< XMLPropertyState > aRowPropStates( mxRowExportPropertySetMapper->Filter( xPropSet ) ); - if( has_states( xRowPropStates ) ) + if( has_states( aRowPropStates ) ) { - const OUString sStyleName( mrExport.GetAutoStylePool()->Add(XML_STYLE_FAMILY_TABLE_ROW, xRowPropStates) ); + const OUString sStyleName( mrExport.GetAutoStylePool()->Add(XML_STYLE_FAMILY_TABLE_ROW, aRowPropStates) ); Reference< XInterface > xKey( xPropSet, UNO_QUERY ); xTableInfo->maRowStyleMap[xKey] = sStyleName; } @@ -261,9 +261,9 @@ static bool has_states( const std::vector< XMLPropertyState >& xPropStates ) // create auto style, if needed OUString sStyleName; - std::vector< XMLPropertyState > xCellPropStates( mxCellExportPropertySetMapper->Filter( xCellSet ) ); - if( has_states( xCellPropStates ) ) - sStyleName = mrExport.GetAutoStylePool()->Add(XML_STYLE_FAMILY_TABLE_CELL, xCellPropStates); + std::vector< XMLPropertyState > aCellPropStates( mxCellExportPropertySetMapper->Filter( xCellSet ) ); + if( has_states( aCellPropStates ) ) + sStyleName = mrExport.GetAutoStylePool()->Add(XML_STYLE_FAMILY_TABLE_CELL, aCellPropStates); else sStyleName = sParentStyleName; diff --git a/xmloff/source/text/txtparae.cxx b/xmloff/source/text/txtparae.cxx index 62be56ba8e93..4b7a823afe19 100644 --- a/xmloff/source/text/txtparae.cxx +++ b/xmloff/source/text/txtparae.cxx @@ -467,19 +467,19 @@ void XMLTextParagraphExport::Add( sal_uInt16 nFamily, } DBG_ASSERT( xPropMapper.is(), "There is the property mapper?" ); - vector< XMLPropertyState > xPropStates = + vector< XMLPropertyState > aPropStates = xPropMapper->Filter( rPropSet ); if( ppAddStates ) { while( *ppAddStates ) { - xPropStates.push_back( **ppAddStates ); + aPropStates.push_back( **ppAddStates ); ppAddStates++; } } - if( !xPropStates.empty() ) + if( !aPropStates.empty() ) { Reference< XPropertySetInfo > xPropSetInfo(rPropSet->getPropertySetInfo()); OUString sParent, sCondParent; @@ -536,8 +536,8 @@ void XMLTextParagraphExport::Add( sal_uInt16 nFamily, { // Get parent and remove hyperlinks (they aren't of interest) rtl::Reference< XMLPropertySetMapper > xPM(xPropMapper->getPropertySetMapper()); - for( ::std::vector< XMLPropertyState >::iterator i(xPropStates.begin()); - nIgnoreProps < 2 && i != xPropStates.end(); ) + for( ::std::vector< XMLPropertyState >::iterator i(aPropStates.begin()); + nIgnoreProps < 2 && i != aPropStates.end(); ) { if( i->mnIndex == -1 ) { @@ -551,7 +551,7 @@ void XMLTextParagraphExport::Add( sal_uInt16 nFamily, case CTF_HYPERLINK_URL: i->mnIndex = -1; nIgnoreProps++; - i = xPropStates.erase( i ); + i = aPropStates.erase( i ); break; default: ++i; @@ -571,11 +571,11 @@ void XMLTextParagraphExport::Add( sal_uInt16 nFamily, ; // section styles have no parents break; } - if( (xPropStates.size() - nIgnoreProps) > 0 ) + if( (aPropStates.size() - nIgnoreProps) > 0 ) { - GetAutoStylePool().Add( nFamily, sParent, xPropStates, bDontSeek ); + GetAutoStylePool().Add( nFamily, sParent, aPropStates, bDontSeek ); if( !sCondParent.isEmpty() && sParent != sCondParent ) - GetAutoStylePool().Add( nFamily, sCondParent, xPropStates ); + GetAutoStylePool().Add( nFamily, sCondParent, aPropStates ); } } } @@ -598,7 +598,7 @@ void XMLTextParagraphExport::Add( sal_uInt16 nFamily, } DBG_ASSERT( xPropMapper.is(), "There is the property mapper?" ); - vector< XMLPropertyState > xPropStates(xPropMapper->Filter( rPropSet )); + vector< XMLPropertyState > aPropStates(xPropMapper->Filter( rPropSet )); if( rPropSetHelper.hasProperty( NUMBERING_RULES_AUTO ) ) { @@ -638,7 +638,7 @@ void XMLTextParagraphExport::Add( sal_uInt16 nFamily, } } - if( !xPropStates.empty() ) + if( !aPropStates.empty() ) { OUString sParent, sCondParent; switch( nFamily ) @@ -658,11 +658,11 @@ void XMLTextParagraphExport::Add( sal_uInt16 nFamily, break; } - if( std::any_of( xPropStates.begin(), xPropStates.end(), lcl_validPropState ) ) + if( std::any_of( aPropStates.begin(), aPropStates.end(), lcl_validPropState ) ) { - GetAutoStylePool().Add( nFamily, sParent, xPropStates ); + GetAutoStylePool().Add( nFamily, sParent, aPropStates ); if( !sCondParent.isEmpty() && sParent != sCondParent ) - GetAutoStylePool().Add( nFamily, sCondParent, xPropStates ); + GetAutoStylePool().Add( nFamily, sCondParent, aPropStates ); } } } @@ -693,17 +693,17 @@ OUString XMLTextParagraphExport::Find( DBG_ASSERT( xPropMapper.is(), "There is the property mapper?" ); if( !xPropMapper.is() ) return sName; - vector< XMLPropertyState > xPropStates(xPropMapper->Filter( rPropSet )); + vector< XMLPropertyState > aPropStates(xPropMapper->Filter( rPropSet )); if( ppAddStates ) { while( *ppAddStates ) { - xPropStates.push_back( **ppAddStates ); + aPropStates.push_back( **ppAddStates ); ++ppAddStates; } } - if( std::any_of( xPropStates.begin(), xPropStates.end(), lcl_validPropState ) ) - sName = GetAutoStylePool().Find( nFamily, sName, xPropStates ); + if( std::any_of( aPropStates.begin(), aPropStates.end(), lcl_validPropState ) ) + sName = GetAutoStylePool().Find( nFamily, sName, aPropStates ); return sName; } @@ -716,19 +716,19 @@ OUString XMLTextParagraphExport::FindTextStyleAndHyperlink( const XMLPropertyState** ppAddStates ) const { rtl::Reference < SvXMLExportPropertyMapper > xPropMapper(GetTextPropMapper()); - vector< XMLPropertyState > xPropStates(xPropMapper->Filter( rPropSet )); + vector< XMLPropertyState > aPropStates(xPropMapper->Filter( rPropSet )); // Get parent and remove hyperlinks (they aren't of interest) OUString sName; rbHyperlink = rbHasCharStyle = rbHasAutoStyle = false; sal_uInt16 nIgnoreProps = 0; rtl::Reference< XMLPropertySetMapper > xPM(xPropMapper->getPropertySetMapper()); - ::std::vector< XMLPropertyState >::iterator aFirstDel = xPropStates.end(); - ::std::vector< XMLPropertyState >::iterator aSecondDel = xPropStates.end(); + ::std::vector< XMLPropertyState >::iterator aFirstDel = aPropStates.end(); + ::std::vector< XMLPropertyState >::iterator aSecondDel = aPropStates.end(); for( ::std::vector< XMLPropertyState >::iterator - i = xPropStates.begin(); - nIgnoreProps < 2 && i != xPropStates.end(); + i = aPropStates.begin(); + nIgnoreProps < 2 && i != aPropStates.end(); ++i ) { if( i->mnIndex == -1 ) @@ -761,11 +761,11 @@ OUString XMLTextParagraphExport::FindTextStyleAndHyperlink( { while( *ppAddStates ) { - xPropStates.push_back( **ppAddStates ); + aPropStates.push_back( **ppAddStates ); ppAddStates++; } } - if( (xPropStates.size() - nIgnoreProps) > 0L ) + if( (aPropStates.size() - nIgnoreProps) > 0L ) { // erase the character style, otherwise the autostyle cannot be found! // erase the hyperlink, otherwise the autostyle cannot be found! @@ -774,11 +774,11 @@ OUString XMLTextParagraphExport::FindTextStyleAndHyperlink( // If two elements of a vector have to be deleted, // we should delete the second one first. if( --nIgnoreProps ) - xPropStates.erase( aSecondDel ); - xPropStates.erase( aFirstDel ); + aPropStates.erase( aSecondDel ); + aPropStates.erase( aFirstDel ); } OUString sParent; // AutoStyles should not have parents! - sName = GetAutoStylePool().Find( XML_STYLE_FAMILY_TEXT_TEXT, sParent, xPropStates ); + sName = GetAutoStylePool().Find( XML_STYLE_FAMILY_TEXT_TEXT, sParent, aPropStates ); rbHasAutoStyle = true; } |