summaryrefslogtreecommitdiff
path: root/sw/source/core
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-12-10 12:27:50 +0200
committerNoel Grandin <noel@peralex.com>2015-12-11 10:11:23 +0200
commit58d8d8ac67aa9b907f1304a48efa0f7a473d9de4 (patch)
treea0d88f3c8a57ce9d08d97c803ea0ec83a3dd8b62 /sw/source/core
parent44ad6aca0dee29841ec7cd15c6d0ad9b3dcaedbe (diff)
tdf#69977: uno::Sequence is expensive
when used as a mutable data-structure. Plain std::vector halves the time taken to display the chart dialog Create a class to represent the std::vector we are going to be passing around, and move some of the utility methods into it to make the code prettier. Also create an optimised append(&&) method for the common case of appending small temporaries. Change-Id: I7f5b43fb4a8a84e40e6a52fcb7e9f974091b4485
Diffstat (limited to 'sw/source/core')
-rw-r--r--sw/source/core/crsr/overlayrangesoutline.cxx6
-rw-r--r--sw/source/core/crsr/overlayrangesoutline.hxx2
-rw-r--r--sw/source/core/doc/notxtfrm.cxx10
-rw-r--r--sw/source/core/draw/dcontact.cxx22
-rw-r--r--sw/source/core/draw/dflyobj.cxx26
-rw-r--r--sw/source/core/graphic/ndgrf.cxx4
-rw-r--r--sw/source/core/inc/frame.hxx2
-rw-r--r--sw/source/core/layout/paintfrm.cxx78
8 files changed, 71 insertions, 79 deletions
diff --git a/sw/source/core/crsr/overlayrangesoutline.cxx b/sw/source/core/crsr/overlayrangesoutline.cxx
index 724e0bf0ed5c..011fc6c393ff 100644
--- a/sw/source/core/crsr/overlayrangesoutline.cxx
+++ b/sw/source/core/crsr/overlayrangesoutline.cxx
@@ -54,9 +54,9 @@ namespace sw
{
namespace overlay
{
- drawinglayer::primitive2d::Primitive2DSequence OverlayRangesOutline::createOverlayObjectPrimitive2DSequence()
+ drawinglayer::primitive2d::Primitive2DContainer OverlayRangesOutline::createOverlayObjectPrimitive2DSequence()
{
- drawinglayer::primitive2d::Primitive2DSequence aRetval;
+ drawinglayer::primitive2d::Primitive2DContainer aRetval;
const sal_uInt32 nCount(getRanges().size());
if( nCount )
@@ -68,7 +68,7 @@ namespace sw
aPolyPolygon,
aRGBColor));
- aRetval.realloc(1);
+ aRetval.resize(1);
aRetval[0] = aOutline;
}
diff --git a/sw/source/core/crsr/overlayrangesoutline.hxx b/sw/source/core/crsr/overlayrangesoutline.hxx
index 2bd9b7734249..0584df449b13 100644
--- a/sw/source/core/crsr/overlayrangesoutline.hxx
+++ b/sw/source/core/crsr/overlayrangesoutline.hxx
@@ -35,7 +35,7 @@ namespace sw
std::vector< basegfx::B2DRange > maRanges;
// geometry creation for OverlayObject
- virtual drawinglayer::primitive2d::Primitive2DSequence createOverlayObjectPrimitive2DSequence() override;
+ virtual drawinglayer::primitive2d::Primitive2DContainer createOverlayObjectPrimitive2DSequence() override;
public:
OverlayRangesOutline(
diff --git a/sw/source/core/doc/notxtfrm.cxx b/sw/source/core/doc/notxtfrm.cxx
index 4267bca0362f..1caa817cbe0b 100644
--- a/sw/source/core/doc/notxtfrm.cxx
+++ b/sw/source/core/doc/notxtfrm.cxx
@@ -706,11 +706,11 @@ static void lcl_correctlyAlignRect( SwRect& rAlignedGrfArea, const SwRect& rInAr
bool paintUsingPrimitivesHelper(
vcl::RenderContext& rOutputDevice,
- const drawinglayer::primitive2d::Primitive2DSequence& rSequence,
+ const drawinglayer::primitive2d::Primitive2DContainer& rSequence,
const basegfx::B2DRange& rSourceRange,
const basegfx::B2DRange& rTargetRange)
{
- if(rSequence.hasElements() && !basegfx::fTools::equalZero(rSourceRange.getWidth()) && !basegfx::fTools::equalZero(rSourceRange.getHeight()))
+ if(!rSequence.empty() && !basegfx::fTools::equalZero(rSourceRange.getWidth()) && !basegfx::fTools::equalZero(rSourceRange.getHeight()))
{
if(!basegfx::fTools::equalZero(rTargetRange.getWidth()) && !basegfx::fTools::equalZero(rTargetRange.getHeight()))
{
@@ -768,7 +768,7 @@ void paintGraphicUsingPrimitivesHelper(vcl::RenderContext & rOutputDevice,
aTargetRange.getRange(),
aTargetRange.getMinimum()));
- drawinglayer::primitive2d::Primitive2DSequence aContent(1);
+ drawinglayer::primitive2d::Primitive2DContainer aContent(1);
bool bDone(false);
// #i125171# The mechanism to get lossless jpegs into pdf is based on having the original
@@ -1000,12 +1000,12 @@ void SwNoTextFrame::PaintPicture( vcl::RenderContext* pOut, const SwRect &rGrfAr
{
basegfx::B2DRange aSourceRange;
- const drawinglayer::primitive2d::Primitive2DSequence aSequence(
+ const drawinglayer::primitive2d::Primitive2DContainer aSequence(
ChartHelper::tryToGetChartContentAsPrimitive2DSequence(
aXModel,
aSourceRange));
- if(aSequence.hasElements() && !aSourceRange.isEmpty())
+ if(!aSequence.empty() && !aSourceRange.isEmpty())
{
const basegfx::B2DRange aTargetRange(
aAlignedGrfArea.Left(), aAlignedGrfArea.Top(),
diff --git a/sw/source/core/draw/dcontact.cxx b/sw/source/core/draw/dcontact.cxx
index 3ded66f433e5..b8304cb75f42 100644
--- a/sw/source/core/draw/dcontact.cxx
+++ b/sw/source/core/draw/dcontact.cxx
@@ -1995,7 +1995,7 @@ namespace sdr
*
* This method will not handle included hierarchies and not check geometric visibility.
*/
- virtual drawinglayer::primitive2d::Primitive2DSequence createPrimitive2DSequence(const DisplayInfo& rDisplayInfo) const override;
+ virtual drawinglayer::primitive2d::Primitive2DContainer createPrimitive2DSequence(const DisplayInfo& rDisplayInfo) const override;
public:
VOCOfDrawVirtObj(ObjectContact& rObjectContact, ViewContact& rViewContact)
@@ -2038,7 +2038,7 @@ namespace sdr
namespace contact
{
/// recursively collect primitive data from given VOC with given offset
- void impAddPrimitivesFromGroup(const ViewObjectContact& rVOC, const basegfx::B2DHomMatrix& rOffsetMatrix, const DisplayInfo& rDisplayInfo, drawinglayer::primitive2d::Primitive2DSequence& rxTarget)
+ void impAddPrimitivesFromGroup(const ViewObjectContact& rVOC, const basegfx::B2DHomMatrix& rOffsetMatrix, const DisplayInfo& rDisplayInfo, drawinglayer::primitive2d::Primitive2DContainer& rxTarget)
{
const sal_uInt32 nSubHierarchyCount(rVOC.GetViewContact().GetObjectCount());
@@ -2056,9 +2056,9 @@ namespace sdr
// single object, add primitives; check model-view visibility
if(rCandidate.isPrimitiveVisible(rDisplayInfo))
{
- drawinglayer::primitive2d::Primitive2DSequence aNewSequence(rCandidate.getPrimitive2DSequence(rDisplayInfo));
+ drawinglayer::primitive2d::Primitive2DContainer aNewSequence(rCandidate.getPrimitive2DSequence(rDisplayInfo));
- if(aNewSequence.hasElements())
+ if(!aNewSequence.empty())
{
// get ranges
const drawinglayer::geometry::ViewInformation2D& rViewInformation2D(rCandidate.GetObjectContact().getViewInformation2D());
@@ -2072,24 +2072,24 @@ namespace sdr
if(!aViewRange.overlaps(aObjectRange))
{
// not visible, release
- aNewSequence.realloc(0);
+ aNewSequence.clear();
}
}
- if(aNewSequence.hasElements())
+ if(!aNewSequence.empty())
{
- drawinglayer::primitive2d::appendPrimitive2DSequenceToPrimitive2DSequence(rxTarget, aNewSequence);
+ rxTarget.append(aNewSequence);
}
}
}
}
}
- drawinglayer::primitive2d::Primitive2DSequence VOCOfDrawVirtObj::createPrimitive2DSequence(const DisplayInfo& rDisplayInfo) const
+ drawinglayer::primitive2d::Primitive2DContainer VOCOfDrawVirtObj::createPrimitive2DSequence(const DisplayInfo& rDisplayInfo) const
{
const VCOfDrawVirtObj& rVC = static_cast< const VCOfDrawVirtObj& >(GetViewContact());
const SdrObject& rReferencedObject = rVC.GetSwDrawVirtObj().GetReferencedObj();
- drawinglayer::primitive2d::Primitive2DSequence xRetval;
+ drawinglayer::primitive2d::Primitive2DContainer xRetval;
// create offset transformation
basegfx::B2DHomMatrix aOffsetMatrix;
@@ -2119,11 +2119,11 @@ namespace sdr
xRetval = rReferencedObject.GetViewContact().getViewIndependentPrimitive2DSequence();
}
- if(xRetval.hasElements())
+ if(!xRetval.empty())
{
// create transform primitive
const drawinglayer::primitive2d::Primitive2DReference xReference(new drawinglayer::primitive2d::TransformPrimitive2D(aOffsetMatrix, xRetval));
- xRetval = drawinglayer::primitive2d::Primitive2DSequence(&xReference, 1);
+ xRetval = drawinglayer::primitive2d::Primitive2DContainer { xReference };
}
return xRetval;
diff --git a/sw/source/core/draw/dflyobj.cxx b/sw/source/core/draw/dflyobj.cxx
index 90262203ad3a..b672d7e40aba 100644
--- a/sw/source/core/draw/dflyobj.cxx
+++ b/sw/source/core/draw/dflyobj.cxx
@@ -84,7 +84,7 @@ namespace sdr
*
* @note ONLY based on model data
*/
- virtual drawinglayer::primitive2d::Primitive2DSequence createViewIndependentPrimitive2DSequence() const override;
+ virtual drawinglayer::primitive2d::Primitive2DContainer createViewIndependentPrimitive2DSequence() const override;
public:
/// basic constructor, used from SdrObject.
@@ -95,10 +95,10 @@ namespace sdr
virtual ~VCOfSwFlyDrawObj();
};
- drawinglayer::primitive2d::Primitive2DSequence VCOfSwFlyDrawObj::createViewIndependentPrimitive2DSequence() const
+ drawinglayer::primitive2d::Primitive2DContainer VCOfSwFlyDrawObj::createViewIndependentPrimitive2DSequence() const
{
// currently gets not visualized, return empty sequence
- return drawinglayer::primitive2d::Primitive2DSequence();
+ return drawinglayer::primitive2d::Primitive2DContainer();
}
VCOfSwFlyDrawObj::~VCOfSwFlyDrawObj()
@@ -154,7 +154,7 @@ namespace drawinglayer
protected:
/// method which is to be used to implement the local decomposition of a 2D primitive
- virtual Primitive2DSequence create2DDecomposition(const geometry::ViewInformation2D& rViewInformation) const override;
+ virtual Primitive2DContainer create2DDecomposition(const geometry::ViewInformation2D& rViewInformation) const override;
public:
SwVirtFlyDrawObjPrimitive(
@@ -171,7 +171,7 @@ namespace drawinglayer
virtual basegfx::B2DRange getB2DRange(const geometry::ViewInformation2D& rViewInformation) const override;
// override to allow callbacks to wrap_DoPaintObject
- virtual Primitive2DSequence get2DDecomposition(const geometry::ViewInformation2D& rViewInformation) const override;
+ virtual Primitive2DContainer get2DDecomposition(const geometry::ViewInformation2D& rViewInformation) const override;
// data read access
const SwVirtFlyDrawObj& getSwVirtFlyDrawObj() const { return mrSwVirtFlyDrawObj; }
@@ -187,9 +187,9 @@ namespace drawinglayer
{
namespace primitive2d
{
- Primitive2DSequence SwVirtFlyDrawObjPrimitive::create2DDecomposition(const geometry::ViewInformation2D& /*rViewInformation*/) const
+ Primitive2DContainer SwVirtFlyDrawObjPrimitive::create2DDecomposition(const geometry::ViewInformation2D& /*rViewInformation*/) const
{
- Primitive2DSequence aRetval;
+ Primitive2DContainer aRetval;
if(!getOuterRange().isEmpty())
{
@@ -204,7 +204,7 @@ namespace drawinglayer
true,
getOuterRange()));
- aRetval = Primitive2DSequence(&aHitTestReference, 1);
+ aRetval = Primitive2DContainer { aHitTestReference };
}
return aRetval;
@@ -228,7 +228,7 @@ namespace drawinglayer
return getOuterRange();
}
- Primitive2DSequence SwVirtFlyDrawObjPrimitive::get2DDecomposition(const geometry::ViewInformation2D& rViewInformation) const
+ Primitive2DContainer SwVirtFlyDrawObjPrimitive::get2DDecomposition(const geometry::ViewInformation2D& rViewInformation) const
{
// This is the callback to keep the FlyFrame painting in SW alive as long as it
// is not changed to primitives. This is the method which will be called by the processors
@@ -263,7 +263,7 @@ namespace sdr
*
* @note ONLY based on model data
*/
- virtual drawinglayer::primitive2d::Primitive2DSequence createViewIndependentPrimitive2DSequence() const override;
+ virtual drawinglayer::primitive2d::Primitive2DContainer createViewIndependentPrimitive2DSequence() const override;
public:
/// basic constructor, used from SdrObject.
@@ -286,9 +286,9 @@ namespace sdr
{
namespace contact
{
- drawinglayer::primitive2d::Primitive2DSequence VCOfSwVirtFlyDrawObj::createViewIndependentPrimitive2DSequence() const
+ drawinglayer::primitive2d::Primitive2DContainer VCOfSwVirtFlyDrawObj::createViewIndependentPrimitive2DSequence() const
{
- drawinglayer::primitive2d::Primitive2DSequence xRetval;
+ drawinglayer::primitive2d::Primitive2DContainer xRetval;
const SdrObject& rReferencedObject = GetSwVirtFlyDrawObj().GetReferencedObj();
if(dynamic_cast<const SwFlyDrawObj*>( &rReferencedObject) != nullptr)
@@ -304,7 +304,7 @@ namespace sdr
GetSwVirtFlyDrawObj(),
aOuterRange));
- xRetval = drawinglayer::primitive2d::Primitive2DSequence(&xPrimitive, 1);
+ xRetval = drawinglayer::primitive2d::Primitive2DContainer { xPrimitive };
}
}
diff --git a/sw/source/core/graphic/ndgrf.cxx b/sw/source/core/graphic/ndgrf.cxx
index d50ac70fe465..98469537cc82 100644
--- a/sw/source/core/graphic/ndgrf.cxx
+++ b/sw/source/core/graphic/ndgrf.cxx
@@ -338,9 +338,9 @@ void SwGrfNode::onGraphicChanged()
if(rSvgDataPtr.get())
{
- const drawinglayer::primitive2d::Primitive2DSequence aSequence(rSvgDataPtr->getPrimitive2DSequence());
+ const drawinglayer::primitive2d::Primitive2DContainer aSequence(rSvgDataPtr->getPrimitive2DSequence());
- if(aSequence.hasElements())
+ if(!aSequence.empty())
{
drawinglayer::geometry::ViewInformation2D aViewInformation2D;
drawinglayer::processor2d::ObjectInfoPrimitiveExtractor2D aProcessor(aViewInformation2D);
diff --git a/sw/source/core/inc/frame.hxx b/sw/source/core/inc/frame.hxx
index e94231525c30..f45b8966a5d5 100644
--- a/sw/source/core/inc/frame.hxx
+++ b/sw/source/core/inc/frame.hxx
@@ -393,7 +393,7 @@ public:
const editeng::SvxBorderStyle = css::table::BorderLineStyle::SOLID ) const;
drawinglayer::processor2d::BaseProcessor2D * CreateProcessor2D( ) const;
- void ProcessPrimitives( const drawinglayer::primitive2d::Primitive2DSequence& rSequence ) const;
+ void ProcessPrimitives( const drawinglayer::primitive2d::Primitive2DContainer& rSequence ) const;
// FIXME: EasyHack (refactoring): rename method name in all files
// retouch, not in the area of the given Rect!
diff --git a/sw/source/core/layout/paintfrm.cxx b/sw/source/core/layout/paintfrm.cxx
index 683202a63037..83a8638d00ab 100644
--- a/sw/source/core/layout/paintfrm.cxx
+++ b/sw/source/core/layout/paintfrm.cxx
@@ -210,22 +210,14 @@ public:
class BorderLines
{
- typedef ::std::vector<
- ::rtl::Reference<BorderLinePrimitive2D> > Lines_t;
- Lines_t m_Lines;
+ drawinglayer::primitive2d::Primitive2DContainer m_Lines;
public:
- void AddBorderLine(::rtl::Reference<BorderLinePrimitive2D> const& xLine, SwPaintProperties& properties);
- drawinglayer::primitive2d::Primitive2DSequence GetBorderLines_Clear()
+ void AddBorderLine(css::uno::Reference<BorderLinePrimitive2D> const& xLine, SwPaintProperties& properties);
+ drawinglayer::primitive2d::Primitive2DContainer GetBorderLines_Clear()
{
- ::std::vector<
- ::drawinglayer::primitive2d::Primitive2DReference> lines;
- for (Lines_t::const_iterator it = m_Lines.begin(); it != m_Lines.end();
- ++it)
- {
- lines.push_back(it->get());
- }
- m_Lines.clear();
- return comphelper::containerToSequence(lines);
+ drawinglayer::primitive2d::Primitive2DContainer lines;
+ lines.swap(m_Lines);
+ return lines;
}
};
@@ -510,7 +502,7 @@ static sal_uInt8 lcl_TryMergeLines(
* @param[in] rEnd ending point of merged primitive
* @return merged primitive
**/
-static ::rtl::Reference<BorderLinePrimitive2D>
+static css::uno::Reference<BorderLinePrimitive2D>
lcl_MergeBorderLines(
BorderLinePrimitive2D const& rLine, BorderLinePrimitive2D const& rOther,
basegfx::B2DPoint const& rStart, basegfx::B2DPoint const& rEnd)
@@ -538,7 +530,7 @@ lcl_MergeBorderLines(
* @return merged borderline including the two input primitive, if they can be merged
* 0, otherwise
**/
-static ::rtl::Reference<BorderLinePrimitive2D>
+static css::uno::Reference<BorderLinePrimitive2D>
lcl_TryMergeBorderLine(BorderLinePrimitive2D const& rThis,
BorderLinePrimitive2D const& rOther,
SwPaintProperties& properties)
@@ -610,13 +602,13 @@ lcl_TryMergeBorderLine(BorderLinePrimitive2D const& rThis,
}
void BorderLines::AddBorderLine(
- rtl::Reference<BorderLinePrimitive2D> const& xLine, SwPaintProperties& properties)
+ css::uno::Reference<BorderLinePrimitive2D> const& xLine, SwPaintProperties& properties)
{
- for (Lines_t::reverse_iterator it = m_Lines.rbegin(); it != m_Lines.rend();
+ for (drawinglayer::primitive2d::Primitive2DContainer::reverse_iterator it = m_Lines.rbegin(); it != m_Lines.rend();
++it)
{
- ::rtl::Reference<BorderLinePrimitive2D> const xMerged =
- lcl_TryMergeBorderLine(**it, *xLine, properties);
+ css::uno::Reference<BorderLinePrimitive2D> const xMerged(
+ lcl_TryMergeBorderLine(*static_cast<BorderLinePrimitive2D*>((*it).get()), *xLine.get(), properties));
if (xMerged.is())
{
*it = xMerged; // replace existing line with merged
@@ -1915,15 +1907,15 @@ bool DrawFillAttributes(
rOriginalLayoutRect.Right(),
rOriginalLayoutRect.Bottom());
- const drawinglayer::primitive2d::Primitive2DSequence& rSequence = rFillAttributes->getPrimitive2DSequence(
+ const drawinglayer::primitive2d::Primitive2DContainer& rSequence = rFillAttributes->getPrimitive2DSequence(
aPaintRange,
aDefineRange);
- if(rSequence.getLength())
+ if(rSequence.size())
{
- drawinglayer::primitive2d::Primitive2DSequence const*
+ drawinglayer::primitive2d::Primitive2DContainer const*
pPrimitives(&rSequence);
- drawinglayer::primitive2d::Primitive2DSequence primitives;
+ drawinglayer::primitive2d::Primitive2DContainer primitives;
// tdf#86578 the awful lcl_SubtractFlys hack
if (rPaintRegion.size() > 1 || rPaintRegion[0] != rPaintRegion.GetOrigin())
{
@@ -1934,12 +1926,12 @@ bool DrawFillAttributes(
}
basegfx::B2DPolyPolygon const maskRegion( tempRegion.getB2DPolyPolygon());
- primitives.realloc(1);
+ primitives.resize(1);
primitives[0] = new drawinglayer::primitive2d::MaskPrimitive2D(
maskRegion, rSequence);
pPrimitives = &primitives;
}
- assert(pPrimitives && pPrimitives->getLength());
+ assert(pPrimitives && pPrimitives->size());
const drawinglayer::geometry::ViewInformation2D aViewInformation2D(
basegfx::B2DHomMatrix(),
@@ -3138,7 +3130,7 @@ namespace
virtual ~SwViewObjectContactRedirector()
{}
- virtual drawinglayer::primitive2d::Primitive2DSequence createRedirectedPrimitive2DSequence(
+ virtual drawinglayer::primitive2d::Primitive2DContainer createRedirectedPrimitive2DSequence(
const sdr::contact::ViewObjectContact& rOriginal,
const sdr::contact::DisplayInfo& rDisplayInfo) override
{
@@ -3152,7 +3144,7 @@ namespace
if ( !bPaint )
{
- return drawinglayer::primitive2d::Primitive2DSequence();
+ return drawinglayer::primitive2d::Primitive2DContainer();
}
return sdr::contact::ViewObjectContactRedirector::createRedirectedPrimitive2DSequence(
@@ -3697,11 +3689,11 @@ void SwLayoutFrame::Paint(vcl::RenderContext& rRenderContext, SwRect const& rRec
}
}
-static drawinglayer::primitive2d::Primitive2DSequence lcl_CreateDashedIndicatorPrimitive(
+static drawinglayer::primitive2d::Primitive2DContainer lcl_CreateDashedIndicatorPrimitive(
const basegfx::B2DPoint& rStart, const basegfx::B2DPoint& rEnd,
basegfx::BColor aColor )
{
- drawinglayer::primitive2d::Primitive2DSequence aSeq( 1 );
+ drawinglayer::primitive2d::Primitive2DContainer aSeq( 1 );
std::vector< double > aStrokePattern;
basegfx::B2DPolygon aLinePolygon;
@@ -3737,7 +3729,7 @@ static drawinglayer::primitive2d::Primitive2DSequence lcl_CreateDashedIndicatorP
aStrokePattern.push_back( 40 );
aStrokePattern.push_back( 40 );
- aSeq.realloc( 2 );
+ aSeq.resize( 2 );
}
// Compute the dashed line primitive
@@ -3747,7 +3739,7 @@ static drawinglayer::primitive2d::Primitive2DSequence lcl_CreateDashedIndicatorP
drawinglayer::attribute::LineAttribute( aColor ),
drawinglayer::attribute::StrokeAttribute( aStrokePattern ) );
- aSeq[ aSeq.getLength( ) - 1 ] = drawinglayer::primitive2d::Primitive2DReference( pLine );
+ aSeq[ aSeq.size( ) - 1 ] = drawinglayer::primitive2d::Primitive2DReference( pLine );
return aSeq;
}
@@ -3829,9 +3821,9 @@ void SwColumnFrame::PaintBreak( ) const
basegfx::BColor aLineColor = SwViewOption::GetPageBreakColor().getBColor();
- drawinglayer::primitive2d::Primitive2DSequence aSeq =
+ drawinglayer::primitive2d::Primitive2DContainer aSeq =
lcl_CreateDashedIndicatorPrimitive( aStart, aEnd, aLineColor );
- aSeq.realloc( aSeq.getLength( ) + 1 );
+ aSeq.resize( aSeq.size( ) + 1 );
// Add the text above
OUString aBreakText = SW_RESSTR(STR_COLUMN_BREAK);
@@ -3866,7 +3858,7 @@ void SwColumnFrame::PaintBreak( ) const
aFontAttr,
lang::Locale(),
aLineColor );
- aSeq[ aSeq.getLength() - 1 ] = drawinglayer::primitive2d::Primitive2DReference( pText );
+ aSeq[ aSeq.size() - 1 ] = drawinglayer::primitive2d::Primitive2DReference( pText );
ProcessPrimitives( aSeq );
}
@@ -4912,7 +4904,7 @@ static void lcl_MakeBorderLine(SwRect const& rRect,
Color const aLeftColor = rBorder.GetColorOut(isLeftOrTopBorder);
Color const aRightColor = rBorder.GetColorIn(isLeftOrTopBorder);
- ::rtl::Reference<BorderLinePrimitive2D> const xLine =
+ css::uno::Reference<BorderLinePrimitive2D> const xLine =
new BorderLinePrimitive2D(
aStart, aEnd, nLeftWidth, rBorder.GetDistance(), nRightWidth,
nExtentLeftStart, nExtentLeftEnd,
@@ -5405,7 +5397,7 @@ drawinglayer::processor2d::BaseProcessor2D * SwFrame::CreateProcessor2D( ) const
aNewViewInfos );
}
-void SwFrame::ProcessPrimitives( const drawinglayer::primitive2d::Primitive2DSequence& rSequence ) const
+void SwFrame::ProcessPrimitives( const drawinglayer::primitive2d::Primitive2DContainer& rSequence ) const
{
drawinglayer::processor2d::BaseProcessor2D * pProcessor2D = CreateProcessor2D();
@@ -6896,10 +6888,10 @@ static void lcl_RefreshLine( const SwLayoutFrame *pLay,
}
}
-static drawinglayer::primitive2d::Primitive2DSequence lcl_CreatePageAreaDelimiterPrimitives(
+static drawinglayer::primitive2d::Primitive2DContainer lcl_CreatePageAreaDelimiterPrimitives(
const SwRect& rRect )
{
- drawinglayer::primitive2d::Primitive2DSequence aSeq( 4 );
+ drawinglayer::primitive2d::Primitive2DContainer aSeq( 4 );
basegfx::BColor aLineColor = SwViewOption::GetDocBoundariesColor().getBColor();
double nLineLength = 200.0; // in Twips
@@ -6930,10 +6922,10 @@ static drawinglayer::primitive2d::Primitive2DSequence lcl_CreatePageAreaDelimite
return aSeq;
}
-static drawinglayer::primitive2d::Primitive2DSequence lcl_CreateRectangleDelimiterPrimitives (
+static drawinglayer::primitive2d::Primitive2DContainer lcl_CreateRectangleDelimiterPrimitives (
const SwRect& rRect )
{
- drawinglayer::primitive2d::Primitive2DSequence aSeq( 1 );
+ drawinglayer::primitive2d::Primitive2DContainer aSeq( 1 );
basegfx::BColor aLineColor = SwViewOption::GetDocBoundariesColor().getBColor();
basegfx::B2DPolygon aPolygon;
@@ -6951,10 +6943,10 @@ static drawinglayer::primitive2d::Primitive2DSequence lcl_CreateRectangleDelimit
return aSeq;
}
-static drawinglayer::primitive2d::Primitive2DSequence lcl_CreateColumnAreaDelimiterPrimitives(
+static drawinglayer::primitive2d::Primitive2DContainer lcl_CreateColumnAreaDelimiterPrimitives(
const SwRect& rRect )
{
- drawinglayer::primitive2d::Primitive2DSequence aSeq( 4 );
+ drawinglayer::primitive2d::Primitive2DContainer aSeq( 4 );
basegfx::BColor aLineColor = SwViewOption::GetDocBoundariesColor().getBColor();
double nLineLength = 100.0; // in Twips