diff options
Diffstat (limited to 'sd/source/ui/view')
31 files changed, 171 insertions, 171 deletions
diff --git a/sd/source/ui/view/DocumentRenderer.cxx b/sd/source/ui/view/DocumentRenderer.cxx index 0eba71c93f37..17d9fa3bdbbf 100644 --- a/sd/source/ui/view/DocumentRenderer.cxx +++ b/sd/source/ui/view/DocumentRenderer.cxx @@ -308,7 +308,7 @@ namespace { pView->DrawMarkedObj(rPrinter); else rPrintView.CompleteRedraw(&rPrinter, - vcl::Region(Rectangle(Point(0,0), rPage.GetSize()))); + vcl::Region(::tools::Rectangle(Point(0,0), rPage.GetSize()))); rPrinter.SetMapMode(aOriginalMapMode); @@ -1106,7 +1106,7 @@ namespace { rPrinter.SetMapMode(maMap); // Get and set up the outliner. - const Rectangle aOutRect (rPrinter.GetPageOffset(), rPrinter.GetOutputSize()); + const ::tools::Rectangle aOutRect (rPrinter.GetPageOffset(), rPrinter.GetOutputSize()); Outliner* pOutliner = rDocument.GetInternalOutliner(); const OutlinerMode nSavedOutlMode (pOutliner->GetMode()); const bool bSavedUpdateMode (pOutliner->GetUpdateMode()); @@ -1535,17 +1535,17 @@ private: const bool bDrawLines (eLayout == AUTOLAYOUT_HANDOUT3); - std::vector< Rectangle > aAreas; + std::vector< ::tools::Rectangle > aAreas; SdPage::CalculateHandoutAreas( rModel, eLayout, bHandoutHorizontal, aAreas ); - std::vector< Rectangle >::iterator iter( aAreas.begin() ); + std::vector< ::tools::Rectangle >::iterator iter( aAreas.begin() ); while( iter != aAreas.end() ) { pHandout->NbcInsertObject( new SdrPageObj((*iter++)) ); if( bDrawLines && (iter != aAreas.end()) ) { - Rectangle aRect( (*iter++) ); + ::tools::Rectangle aRect( (*iter++) ); basegfx::B2DPolygon aPoly; aPoly.insert(0, basegfx::B2DPoint( aRect.Left(), aRect.Top() ) ); @@ -1606,7 +1606,7 @@ private: aMap.SetScaleY(Fraction(1,2)); mpPrinter->SetMapMode(aMap); - Rectangle aOutRect(aPageOfs, rInfo.mpPrinter->GetOutputSize()); + ::tools::Rectangle aOutRect(aPageOfs, rInfo.mpPrinter->GetOutputSize()); if( aOutRect.GetWidth() > aOutRect.GetHeight() ) { Size aPaperSize( rInfo.mpPrinter->PixelToLogic( rInfo.mpPrinter->GetPaperSizePixel(), MapMode( MapUnit::Map100thMM ) ) ); @@ -1614,7 +1614,7 @@ private: maPrintSize.Height = aPaperSize.Width(); const long nRotatedWidth = aOutRect.GetHeight(); const long nRotatedHeight = aOutRect.GetWidth(); - aOutRect = Rectangle( Point( aPageOfs.Y(), aPageOfs.X() ), + aOutRect = ::tools::Rectangle( Point( aPageOfs.Y(), aPageOfs.X() ), Size( nRotatedWidth, nRotatedHeight ) ); } diff --git a/sd/source/ui/view/Outliner.cxx b/sd/source/ui/view/Outliner.cxx index 9b4fe138301c..cd38117db3da 100644 --- a/sd/source/ui/view/Outliner.cxx +++ b/sd/source/ui/view/Outliner.cxx @@ -800,11 +800,11 @@ bool SdOutliner::SearchAndReplaceOnce(std::vector<sd::SearchSelection>* pSelecti if (pViewShell && comphelper::LibreOfficeKit::isActive() && mbStringFound) { - std::vector<Rectangle> aLogicRects; + std::vector<::tools::Rectangle> aLogicRects; pOutlinerView->GetSelectionRectangles(aLogicRects); std::vector<OString> aLogicRectStrings; - std::transform(aLogicRects.begin(), aLogicRects.end(), std::back_inserter(aLogicRectStrings), [](const Rectangle& rRectangle) { return rRectangle.toString(); }); + std::transform(aLogicRects.begin(), aLogicRects.end(), std::back_inserter(aLogicRectStrings), [](const ::tools::Rectangle& rRectangle) { return rRectangle.toString(); }); OString sRectangles = comphelper::string::join("; ", aLogicRectStrings); if (!pSelections) @@ -869,7 +869,7 @@ void SdOutliner::DetectChange() SetUpdateMode(false); OutlinerView* pOutlinerView = mpImpl->GetOutlinerView(); if (pOutlinerView != nullptr) - pOutlinerView->SetOutputArea( Rectangle( Point(), Size(1, 1) ) ); + pOutlinerView->SetOutputArea( ::tools::Rectangle( Point(), Size(1, 1) ) ); if (meMode == SPELL) SetPaperSize( Size(1, 1) ); SetText(OUString(), GetParagraph(0)); @@ -1061,7 +1061,7 @@ void SdOutliner::ProvideNextTextObject() SetUpdateMode(false); OutlinerView* pOutlinerView = mpImpl->GetOutlinerView(); if (pOutlinerView != nullptr) - pOutlinerView->SetOutputArea( Rectangle( Point(), Size(1, 1) ) ); + pOutlinerView->SetOutputArea( ::tools::Rectangle( Point(), Size(1, 1) ) ); if (meMode == SPELL) SetPaperSize( Size(1, 1) ); SetText(OUString(), GetParagraph(0)); @@ -1408,7 +1408,7 @@ void SdOutliner::EnterEditMode (bool bGrabFocus) OutlinerView* pOutlinerView = mpImpl->GetOutlinerView(); if (pOutlinerView && mpTextObj) { - pOutlinerView->SetOutputArea( Rectangle( Point(), Size(1, 1))); + pOutlinerView->SetOutputArea( ::tools::Rectangle( Point(), Size(1, 1))); SetPaperSize( mpTextObj->GetLogicRect().GetSize() ); SdrPageView* pPV = mpView->GetSdrPageView(); @@ -1785,7 +1785,7 @@ void SdOutliner::Implementation::ProvideOutlinerView ( rOutliner.InsertView( mpOutlineView ); rOutliner.SetUpdateMode(false); - mpOutlineView->SetOutputArea (Rectangle (Point(), Size(1, 1))); + mpOutlineView->SetOutputArea (::tools::Rectangle (Point(), Size(1, 1))); rOutliner.SetPaperSize( Size(1, 1) ); rOutliner.SetText(OUString(), rOutliner.GetParagraph(0)); diff --git a/sd/source/ui/view/ViewShellBase.cxx b/sd/source/ui/view/ViewShellBase.cxx index c1f7efcdad24..a2263c38c9e6 100644 --- a/sd/source/ui/view/ViewShellBase.cxx +++ b/sd/source/ui/view/ViewShellBase.cxx @@ -138,7 +138,7 @@ public: ::rtl::Reference<ViewTabBar> mpViewTabBar; // contains the complete area of the current view relative to the frame window - Rectangle maClientArea; + ::tools::Rectangle maClientArea; // This is set to true when PrepareClose() is called. bool mbIsClosing; @@ -931,7 +931,7 @@ std::shared_ptr<tools::EventMultiplexer> ViewShellBase::GetEventMultiplexer() return mpImpl->mpEventMultiplexer; } -const Rectangle& ViewShellBase::getClientRectangle() const +const ::tools::Rectangle& ViewShellBase::getClientRectangle() const { return mpImpl->maClientArea; } @@ -1020,7 +1020,7 @@ void ViewShellBase::NotifyCursor(SfxViewShell* pOtherShell) const // Shape text lock. if (OutlinerView* pOutlinerView = pDrawView->GetTextEditOutlinerView()) { - Rectangle aRectangle = pOutlinerView->GetOutputArea(); + ::tools::Rectangle aRectangle = pOutlinerView->GetOutputArea(); vcl::Window* pWin = pThisShell->GetActiveWindow(); if (pWin && pWin->GetMapMode().GetMapUnit() == MapUnit::Map100thMM) aRectangle = OutputDevice::LogicToLogic(aRectangle, MapUnit::Map100thMM, MapUnit::MapTwip); @@ -1157,7 +1157,7 @@ void ViewShellBase::Implementation::ResizePixel ( rSize.Height() - aBaseBorder.Top() - aBaseBorder.Bottom()); mpViewWindow->SetPosSizePixel(aViewWindowPosition, aViewWindowSize); - maClientArea = Rectangle(Point(0,0), aViewWindowSize); + maClientArea = ::tools::Rectangle(Point(0,0), aViewWindowSize); } void ViewShellBase::Implementation::SetPaneVisibility ( diff --git a/sd/source/ui/view/ViewTabBar.cxx b/sd/source/ui/view/ViewTabBar.cxx index 30aa66ddfff9..e09f36fc0a64 100644 --- a/sd/source/ui/view/ViewTabBar.cxx +++ b/sd/source/ui/view/ViewTabBar.cxx @@ -65,7 +65,7 @@ class TabBarControl : public ::TabControl { public: TabBarControl (vcl::Window* pParentWindow, const ::rtl::Reference<ViewTabBar>& rpViewTabBar); - virtual void Paint (vcl::RenderContext& rRenderContext, const Rectangle& rRect) override; + virtual void Paint (vcl::RenderContext& rRenderContext, const ::tools::Rectangle& rRect) override; virtual void ActivatePage() override; private: ::rtl::Reference<ViewTabBar> mpViewTabBar; @@ -550,7 +550,7 @@ TabBarControl::TabBarControl ( { } -void TabBarControl::Paint (vcl::RenderContext& rRenderContext, const Rectangle& rRect) +void TabBarControl::Paint (vcl::RenderContext& rRenderContext, const ::tools::Rectangle& rRect) { Color aOriginalFillColor(rRenderContext.GetFillColor()); Color aOriginalLineColor(rRenderContext.GetLineColor()); diff --git a/sd/source/ui/view/clview.cxx b/sd/source/ui/view/clview.cxx index 986481ad860c..c92c3a16a55f 100644 --- a/sd/source/ui/view/clview.cxx +++ b/sd/source/ui/view/clview.cxx @@ -59,7 +59,7 @@ void ClientView::InvalidateOneWin(vcl::Window& rWin) * to be overridden and properly handled. */ -void ClientView::InvalidateOneWin(vcl::Window& rWin, const Rectangle& rRect) +void ClientView::InvalidateOneWin(vcl::Window& rWin, const ::tools::Rectangle& rRect) { CompleteRedraw(&rWin, vcl::Region(rRect)); } diff --git a/sd/source/ui/view/drawview.cxx b/sd/source/ui/view/drawview.cxx index 355b0a3f1abf..fd74fd14a497 100644 --- a/sd/source/ui/view/drawview.cxx +++ b/sd/source/ui/view/drawview.cxx @@ -489,7 +489,7 @@ void DrawView::CompleteRedraw(OutputDevice* pOutDev, const vcl::Region& rReg, sd * Make passed region visible (scrolling if necessary) */ -void DrawView::MakeVisible(const Rectangle& rRect, vcl::Window& rWin) +void DrawView::MakeVisible(const ::tools::Rectangle& rRect, vcl::Window& rWin) { if (!rRect.IsEmpty() && mpDrawViewShell) { @@ -558,7 +558,7 @@ void DrawView::DeleteMarked() } SdrTextObj* pTextObj = dynamic_cast< SdrTextObj* >( pObj ); bool bVertical = pTextObj && pTextObj->IsVerticalWriting(); - Rectangle aRect( pObj->GetLogicRect() ); + ::tools::Rectangle aRect( pObj->GetLogicRect() ); SdrObject* pNewObj = pPage->InsertAutoLayoutShape( nullptr, ePresObjKind, bVertical, aRect, true ); // pUndoManager should not be NULL (see assert above) diff --git a/sd/source/ui/view/drviews1.cxx b/sd/source/ui/view/drviews1.cxx index 830953a22dcc..1331c26b394d 100644 --- a/sd/source/ui/view/drviews1.cxx +++ b/sd/source/ui/view/drviews1.cxx @@ -287,7 +287,7 @@ void DrawViewShell::SetZoom( long nZoom ) * Set zoom rectangle for active window */ -void DrawViewShell::SetZoomRect( const Rectangle& rZoomRect ) +void DrawViewShell::SetZoomRect( const ::tools::Rectangle& rZoomRect ) { ViewShell::SetZoomRect( rZoomRect ); GetViewFrame()->GetBindings().Invalidate( SID_ATTR_ZOOM ); @@ -932,7 +932,7 @@ bool DrawViewShell::SwitchPage(sal_uInt16 nSelectedPage) // !!! only if we are not in presentation mode (#96279) !!! OSL_ASSERT (GetViewShell()!=nullptr); GetViewShell()->DisconnectAllClients(); - VisAreaChanged(Rectangle(Point(), Size(1, 1))); + VisAreaChanged(::tools::Rectangle(Point(), Size(1, 1))); } if (meEditMode == EditMode::Page) @@ -1090,7 +1090,7 @@ bool DrawViewShell::SwitchPage(sal_uInt16 nSelectedPage) } Size aVisSizePixel = GetActiveWindow()->GetOutputSizePixel(); - Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( Rectangle( Point(0,0), aVisSizePixel) ); + ::tools::Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), aVisSizePixel) ); VisAreaChanged(aVisAreaWin); mpDrawView->VisAreaChanged(GetActiveWindow()); diff --git a/sd/source/ui/view/drviews2.cxx b/sd/source/ui/view/drviews2.cxx index 292067501d6b..fa8024e0a8c9 100644 --- a/sd/source/ui/view/drviews2.cxx +++ b/sd/source/ui/view/drviews2.cxx @@ -738,7 +738,7 @@ void DrawViewShell::FuTemporary(SfxRequest& rReq) OSL_ENSURE(pPageView, "DrawViewShell::FuTemporary: SID_CONVERT_TO_BITMAP without SdrPageView (!)"); // fit rectangle of new graphic object to selection's mark rect - Rectangle aAllMarkedRect; + ::tools::Rectangle aAllMarkedRect; rMarkList.TakeBoundRect(pPageView, aAllMarkedRect); pGraphicObj->SetLogicRect(aAllMarkedRect); @@ -1940,13 +1940,13 @@ void DrawViewShell::FuTemporary(SfxRequest& rReq) pOutl->SetUpdateMode( false ); Point aPos; - Rectangle aRect( aPos, GetActiveWindow()->GetOutputSizePixel() ); + ::tools::Rectangle aRect( aPos, GetActiveWindow()->GetOutputSizePixel() ); aPos = aRect.Center(); aPos = GetActiveWindow()->PixelToLogic(aPos); aPos.X() -= aSize.Width() / 2; aPos.Y() -= aSize.Height() / 2; - Rectangle aLogicRect(aPos, aSize); + ::tools::Rectangle aLogicRect(aPos, aSize); pRectObj->SetLogicRect(aLogicRect); pRectObj->SetOutlinerParaObject( pOutlParaObject ); mpDrawView->InsertObjectAtView(pRectObj, *mpDrawView->GetSdrPageView()); diff --git a/sd/source/ui/view/drviews3.cxx b/sd/source/ui/view/drviews3.cxx index 3a56d0d0d4fa..4aff2371708d 100644 --- a/sd/source/ui/view/drviews3.cxx +++ b/sd/source/ui/view/drviews3.cxx @@ -334,7 +334,7 @@ void DrawViewShell::ExecCtrl(SfxRequest& rReq) { const SfxRectangleItem& rRect = static_cast<const SfxRectangleItem&>(rReq.GetArgs()->Get(SID_OBJECTRESIZE)); - Rectangle aRect( GetActiveWindow()->PixelToLogic( rRect.GetValue() ) ); + ::tools::Rectangle aRect( GetActiveWindow()->PixelToLogic( rRect.GetValue() ) ); if ( mpDrawView->AreObjectsMarked() ) { @@ -503,7 +503,7 @@ void DrawViewShell::ExecRuler(SfxRequest& rReq) if( mpDrawView->IsTextEdit() ) { - Rectangle aRect = maMarkRect; + ::tools::Rectangle aRect = maMarkRect; aRect.SetPos(aRect.TopLeft() + aPagePos); aRect.Left() = rLRSpace.GetLeft(); aRect.Right() = aViewSize.Width() - rLRSpace.GetRight(); @@ -568,7 +568,7 @@ void DrawViewShell::ExecRuler(SfxRequest& rReq) if( mpDrawView->IsTextEdit() ) { - Rectangle aRect = maMarkRect; + ::tools::Rectangle aRect = maMarkRect; aRect.SetPos(aRect.TopLeft() + aPagePos); aRect.Top() = rULSpace.GetUpper(); aRect.Bottom() = aViewSize.Height() - rULSpace.GetLower(); @@ -626,7 +626,7 @@ void DrawViewShell::ExecRuler(SfxRequest& rReq) case SID_RULER_OBJECT: if (pArgs) { - Rectangle aRect = maMarkRect; + ::tools::Rectangle aRect = maMarkRect; aRect.SetPos(aRect.TopLeft() + aPagePos); const SvxObjectItem& rOI = static_cast<const SvxObjectItem&>( @@ -861,13 +861,13 @@ void DrawViewShell::GetRulerState(SfxItemSet& rSet) const Point aPagePos( GetActiveWindow()->GetViewOrigin() ); Size aPageSize = mpActualPage->GetSize(); - Rectangle aRect(aPagePos, Point( aViewSize.Width() - (aPagePos.X() + aPageSize.Width()), + ::tools::Rectangle aRect(aPagePos, Point( aViewSize.Width() - (aPagePos.X() + aPageSize.Width()), aViewSize.Height() - (aPagePos.Y() + aPageSize.Height()))); if( mpDrawView->IsTextEdit() ) { Point aPnt1 = GetActiveWindow()->GetWinViewPos(); - Rectangle aMinMaxRect = Rectangle( aPnt1, Size(ULONG_MAX, ULONG_MAX) ); + ::tools::Rectangle aMinMaxRect = ::tools::Rectangle( aPnt1, Size(ULONG_MAX, ULONG_MAX) ); rSet.Put( SfxRectangleItem(SID_RULER_LR_MIN_MAX, aMinMaxRect) ); } else @@ -974,7 +974,7 @@ void DrawViewShell::GetRulerState(SfxItemSet& rSet) if( mpDrawView->IsResizeAllowed(true) ) { - Rectangle aResizeRect( maMarkRect ); + ::tools::Rectangle aResizeRect( maMarkRect ); aResizeRect.SetPos(aResizeRect.TopLeft() + aPagePos); SvxObjectItem aObjItem(aResizeRect.Left(), aResizeRect.Right(), diff --git a/sd/source/ui/view/drviews4.cxx b/sd/source/ui/view/drviews4.cxx index 3ce20cdb5796..fc5d537e2796 100644 --- a/sd/source/ui/view/drviews4.cxx +++ b/sd/source/ui/view/drviews4.cxx @@ -304,7 +304,7 @@ void DrawViewShell::MouseMove(const MouseEvent& rMEvt, ::sd::Window* pWin) { if ( mpDrawView->IsAction() ) { - Rectangle aOutputArea(Point(0,0), GetActiveWindow()->GetOutputSizePixel()); + ::tools::Rectangle aOutputArea(Point(0,0), GetActiveWindow()->GetOutputSizePixel()); if ( !aOutputArea.IsInside(rMEvt.GetPosPixel()) ) { @@ -312,7 +312,7 @@ void DrawViewShell::MouseMove(const MouseEvent& rMEvt, ::sd::Window* pWin) if (mpContentWindow.get() != nullptr) { - aOutputArea = Rectangle(Point(0,0), + aOutputArea = ::tools::Rectangle(Point(0,0), mpContentWindow->GetOutputSizePixel()); Point aPos = mpContentWindow->GetPointerPosPixel(); @@ -350,7 +350,7 @@ void DrawViewShell::MouseMove(const MouseEvent& rMEvt, ::sd::Window* pWin) if( !mbMousePosFreezed ) maMousePos = rMEvt.GetPosPixel(); - Rectangle aRect; + ::tools::Rectangle aRect; if ( mbIsRulerDrag ) { @@ -365,7 +365,7 @@ void DrawViewShell::MouseMove(const MouseEvent& rMEvt, ::sd::Window* pWin) } else { - aRect = Rectangle(maMousePos, maMousePos); + aRect = ::tools::Rectangle(maMousePos, maMousePos); } ShowMousePosInfo(aRect, pWin); @@ -415,7 +415,7 @@ void DrawViewShell::MouseButtonUp(const MouseEvent& rMEvt, ::sd::Window* pWin) if (mbIsRulerDrag) { - Rectangle aOutputArea(Point(0,0), GetActiveWindow()->GetOutputSizePixel()); + ::tools::Rectangle aOutputArea(Point(0,0), GetActiveWindow()->GetOutputSizePixel()); if (aOutputArea.IsInside(rMEvt.GetPosPixel())) { @@ -752,7 +752,7 @@ void DrawViewShell::Command(const CommandEvent& rCEvt, ::sd::Window* pWin) //middle of the bounding rect if something is marked if( mpDrawView->AreObjectsMarked() && mpDrawView->GetMarkedObjectList().GetMarkCount() >= 1 ) { - Rectangle aMarkRect; + ::tools::Rectangle aMarkRect; mpDrawView->GetMarkedObjectList().TakeBoundRect(nullptr,aMarkRect); aMenuPos = GetActiveWindow()->LogicToPixel( aMarkRect.Center() ); @@ -780,7 +780,7 @@ void DrawViewShell::Command(const CommandEvent& rCEvt, ::sd::Window* pWin) } } -void DrawViewShell::ShowMousePosInfo(const Rectangle& rRect, +void DrawViewShell::ShowMousePosInfo(const ::tools::Rectangle& rRect, ::sd::Window* pWin) { if (mbHasRulers && pWin ) @@ -896,7 +896,7 @@ void DrawViewShell::ShowSnapLineContextMenu ( const sal_uInt16 nResult = pMenu->Execute( GetActiveWindow(), - Rectangle(rMouseLocation, Size(10,10)), + ::tools::Rectangle(rMouseLocation, Size(10,10)), PopupMenuFlags::ExecuteDown); switch (nResult) { diff --git a/sd/source/ui/view/drviews5.cxx b/sd/source/ui/view/drviews5.cxx index 372de4953ada..bf487fba1762 100644 --- a/sd/source/ui/view/drviews5.cxx +++ b/sd/source/ui/view/drviews5.cxx @@ -347,7 +347,7 @@ void DrawViewShell::WriteFrameViewData() mpFrameView->SetDesignMode( mpDrawView->IsDesignMode() ); Size aVisSizePixel = GetActiveWindow()->GetOutputSizePixel(); - Rectangle aVisArea = GetActiveWindow()->PixelToLogic( Rectangle( Point(0,0), aVisSizePixel) ); + ::tools::Rectangle aVisArea = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), aVisSizePixel) ); mpFrameView->SetVisArea(aVisArea); if( mePageKind == PageKind::Handout ) @@ -406,7 +406,7 @@ void DrawViewShell::PrePaint() * * Remark: pWin==NULL, if Paint() is called from ShowWindow! */ -void DrawViewShell::Paint(const Rectangle& rRect, ::sd::Window* pWin) +void DrawViewShell::Paint(const ::tools::Rectangle& rRect, ::sd::Window* pWin) { /* This is done before each text edit, so why not do it before every paint. The default language is only used if the outliner only contains one @@ -501,7 +501,7 @@ void DrawViewShell::ReadUserDataSequence ( const css::uno::Sequence < css::beans if( !mbZoomOnPage ) { - const Rectangle aVisArea( mpFrameView->GetVisArea() ); + const ::tools::Rectangle aVisArea( mpFrameView->GetVisArea() ); if ( GetDocSh()->GetCreateMode() == SfxObjectCreateMode::EMBEDDED ) { @@ -523,7 +523,7 @@ void DrawViewShell::ReadUserDataSequence ( const css::uno::Sequence < css::beans ResetActualLayer(); } -void DrawViewShell::VisAreaChanged(const Rectangle& rRect) +void DrawViewShell::VisAreaChanged(const ::tools::Rectangle& rRect) { ViewShell::VisAreaChanged( rRect ); diff --git a/sd/source/ui/view/drviews7.cxx b/sd/source/ui/view/drviews7.cxx index 0e540b7bd7b0..82209d72ca4a 100644 --- a/sd/source/ui/view/drviews7.cxx +++ b/sd/source/ui/view/drviews7.cxx @@ -1326,7 +1326,7 @@ void DrawViewShell::GetMenuState( SfxItemSet &rSet ) const SdrGrafObj* pSdrGrafObj = static_cast< const SdrGrafObj* >(pObj); // Current size of the OBJ_GRAF - const Rectangle aRect = pObj->GetLogicRect(); + const ::tools::Rectangle aRect = pObj->GetLogicRect(); const Size aCurrentSizeofObj = aRect.GetSize(); // Original size of the OBJ_GRAF diff --git a/sd/source/ui/view/drviews8.cxx b/sd/source/ui/view/drviews8.cxx index f1c07f6102ed..8c23c9656f3a 100644 --- a/sd/source/ui/view/drviews8.cxx +++ b/sd/source/ui/view/drviews8.cxx @@ -97,7 +97,7 @@ void DrawViewShell::ScannerEvent( const css::lang::EventObject& ) Point aPnt ( ( aPageSize.Width() - aBmpSize.Width() ) >> 1, ( aPageSize.Height() - aBmpSize.Height() ) >> 1 ); aPnt += Point( pPage->GetLftBorder(), pPage->GetUppBorder() ); - Rectangle aRect( aPnt, aBmpSize ); + ::tools::Rectangle aRect( aPnt, aBmpSize ); SdrGrafObj* pGrafObj = nullptr; bool bInsertNewObject = true; diff --git a/sd/source/ui/view/drviews9.cxx b/sd/source/ui/view/drviews9.cxx index 438560f70342..1bf00f00e603 100644 --- a/sd/source/ui/view/drviews9.cxx +++ b/sd/source/ui/view/drviews9.cxx @@ -126,7 +126,7 @@ void DrawViewShell::ExecGallery(SfxRequest& rReq) Point aPnt ((aPageSize.Width() - aSize.Width()) / 2, (aPageSize.Height() - aSize.Height()) / 2); aPnt += Point(pPage->GetLftBorder(), pPage->GetUppBorder()); - Rectangle aRect (aPnt, aSize); + ::tools::Rectangle aRect (aPnt, aSize); SdrGrafObj* pGrafObj = nullptr; diff --git a/sd/source/ui/view/drviewsa.cxx b/sd/source/ui/view/drviewsa.cxx index 2f1968695614..24269c22ef43 100644 --- a/sd/source/ui/view/drviewsa.cxx +++ b/sd/source/ui/view/drviewsa.cxx @@ -249,7 +249,7 @@ void DrawViewShell::Construct(DrawDocShell* pDocSh, PageKind eInitialPageKind) aVisAreaPos = pDocSh->GetVisArea(ASPECT_CONTENT).TopLeft(); } - mpDrawView->SetWorkArea(Rectangle(Point() - aVisAreaPos - aPageOrg, aSize)); + mpDrawView->SetWorkArea(::tools::Rectangle(Point() - aVisAreaPos - aPageOrg, aSize)); // objects can not grow bigger than ViewSize GetDoc()->SetMaxObjSize(aSize); @@ -433,7 +433,7 @@ void DrawViewShell::SetupPage (Size &rSize, { if( bSize ) { - Rectangle aBorderRect(nLeft, nUpper, nRight, nLower); + ::tools::Rectangle aBorderRect(nLeft, nUpper, nRight, nLower); pPage->ScaleObjects(rSize, aBorderRect, bScaleAll); pPage->SetSize(rSize); @@ -466,7 +466,7 @@ void DrawViewShell::SetupPage (Size &rSize, { if( bSize ) { - Rectangle aBorderRect(nLeft, nUpper, nRight, nLower); + ::tools::Rectangle aBorderRect(nLeft, nUpper, nRight, nLower); pPage->ScaleObjects(rSize, aBorderRect, bScaleAll); pPage->SetSize(rSize); } @@ -509,7 +509,7 @@ void DrawViewShell::SetupPage (Size &rSize, aVisAreaPos = GetDocSh()->GetVisArea(ASPECT_CONTENT).TopLeft(); } - GetView()->SetWorkArea(Rectangle(Point() - aVisAreaPos - aPageOrg, aSize)); + GetView()->SetWorkArea(::tools::Rectangle(Point() - aVisAreaPos - aPageOrg, aSize)); UpdateScrollBars(); @@ -585,7 +585,7 @@ void DrawViewShell::GetStatusBarState(SfxItemSet& rSet) aPagePos.X() -= aPageSize.Width() / 2; - Rectangle aFullPageZoomRect( aPagePos, aPageSize ); + ::tools::Rectangle aFullPageZoomRect( aPagePos, aPageSize ); aZoomItem.AddSnappingPoint( pActiveWindow->GetZoomForRect( aFullPageZoomRect ) ); } aZoomItem.AddSnappingPoint(100); @@ -605,7 +605,7 @@ void DrawViewShell::GetStatusBarState(SfxItemSet& rSet) // position- and size items if ( mpDrawView->IsAction() ) { - Rectangle aRect; + ::tools::Rectangle aRect; mpDrawView->TakeActionRect( aRect ); if ( aRect.IsEmpty() ) @@ -627,7 +627,7 @@ void DrawViewShell::GetStatusBarState(SfxItemSet& rSet) { if ( mpDrawView->AreObjectsMarked() ) { - Rectangle aRect = mpDrawView->GetAllMarkedRect(); + ::tools::Rectangle aRect = mpDrawView->GetAllMarkedRect(); pPageView->LogicToPagePos(aRect); // Show the position of the selected shape(s) diff --git a/sd/source/ui/view/drviewse.cxx b/sd/source/ui/view/drviewse.cxx index 8885953bf0e4..0c9eb63b06a7 100644 --- a/sd/source/ui/view/drviewse.cxx +++ b/sd/source/ui/view/drviewse.cxx @@ -276,12 +276,12 @@ void DrawViewShell::FuPermanent(SfxRequest& rReq) if(pNewDBField) { - Rectangle aVisArea = GetActiveWindow()->PixelToLogic(Rectangle(Point(0,0), GetActiveWindow()->GetOutputSizePixel())); + ::tools::Rectangle aVisArea = GetActiveWindow()->PixelToLogic(::tools::Rectangle(Point(0,0), GetActiveWindow()->GetOutputSizePixel())); Point aObjPos(aVisArea.Center()); Size aObjSize(pNewDBField->GetLogicRect().GetSize()); aObjPos.X() -= aObjSize.Width() / 2; aObjPos.Y() -= aObjSize.Height() / 2; - Rectangle aNewObjectRectangle(aObjPos, aObjSize); + ::tools::Rectangle aNewObjectRectangle(aObjPos, aObjSize); pNewDBField->SetLogicRect(aNewObjectRectangle); @@ -589,11 +589,11 @@ void DrawViewShell::FuPermanent(SfxRequest& rReq) sal_uInt32 nDefaultObjectSizeHeight(pOptions->GetDefaultObjectSizeHeight()); // calc position and size - Rectangle aVisArea = GetActiveWindow()->PixelToLogic(Rectangle(Point(0,0), GetActiveWindow()->GetOutputSizePixel())); + ::tools::Rectangle aVisArea = GetActiveWindow()->PixelToLogic(::tools::Rectangle(Point(0,0), GetActiveWindow()->GetOutputSizePixel())); Point aPagePos = aVisArea.Center(); aPagePos.X() -= nDefaultObjectSizeWidth / 2; aPagePos.Y() -= nDefaultObjectSizeHeight / 2; - Rectangle aNewObjectRectangle(aPagePos, Size(nDefaultObjectSizeWidth, nDefaultObjectSizeHeight)); + ::tools::Rectangle aNewObjectRectangle(aPagePos, Size(nDefaultObjectSizeWidth, nDefaultObjectSizeHeight)); SdrPageView* pPageView = mpDrawView->GetSdrPageView(); if(pPageView) @@ -896,7 +896,7 @@ void DrawViewShell::FuSupport(SfxRequest& rReq) if (aDataHelper.GetTransferable().is()) { mpDrawView->InsertData( aDataHelper, - GetActiveWindow()->PixelToLogic( Rectangle( Point(), GetActiveWindow()->GetOutputSizePixel() ).Center() ), + GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(), GetActiveWindow()->GetOutputSizePixel() ).Center() ), nAction, false, SotClipboardFormatId::STRING); } } @@ -923,7 +923,7 @@ void DrawViewShell::FuSupport(SfxRequest& rReq) sal_Int8 nAction = DND_ACTION_COPY; if( !mpDrawView->InsertData( aDataHelper, - GetActiveWindow()->PixelToLogic( Rectangle( Point(), GetActiveWindow()->GetOutputSizePixel() ).Center() ), + GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(), GetActiveWindow()->GetOutputSizePixel() ).Center() ), nAction, false, nFormat ) ) { INetBookmark aINetBookmark( "", "" ); @@ -1106,9 +1106,9 @@ void DrawViewShell::FuSupport(SfxRequest& rReq) aPagePos.X() -= aPageSize.Width() / 2; - SetZoomRect( Rectangle( aPagePos, aPageSize ) ); + SetZoomRect( ::tools::Rectangle( aPagePos, aPageSize ) ); - Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( Rectangle( Point(0,0), + ::tools::Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), GetActiveWindow()->GetOutputSizePixel()) ); mpZoomList->InsertZoomRect(aVisAreaWin); } @@ -1123,7 +1123,7 @@ void DrawViewShell::FuSupport(SfxRequest& rReq) { mbZoomOnPage = false; SetZoom( 100 ); - Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( Rectangle( Point(0,0), + ::tools::Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), GetActiveWindow()->GetOutputSizePixel()) ); mpZoomList->InsertZoomRect(aVisAreaWin); Invalidate( SID_ZOOM_IN ); @@ -1137,7 +1137,7 @@ void DrawViewShell::FuSupport(SfxRequest& rReq) { mbZoomOnPage = false; SetZoom( std::max( (long) ( GetActiveWindow()->GetZoom() / 2 ), (long) GetActiveWindow()->GetMinZoom() ) ); - Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( Rectangle( Point(0,0), + ::tools::Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), GetActiveWindow()->GetOutputSizePixel()) ); mpZoomList->InsertZoomRect(aVisAreaWin); Invalidate( SID_ZOOM_IN ); @@ -1151,7 +1151,7 @@ void DrawViewShell::FuSupport(SfxRequest& rReq) { mbZoomOnPage = false; SetZoom( std::min( (long) ( GetActiveWindow()->GetZoom() * 2 ), (long) GetActiveWindow()->GetMaxZoom() ) ); - Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( Rectangle( Point(0,0), + ::tools::Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), GetActiveWindow()->GetOutputSizePixel()) ); mpZoomList->InsertZoomRect(aVisAreaWin); Invalidate( SID_ZOOM_IN ); @@ -1162,7 +1162,7 @@ void DrawViewShell::FuSupport(SfxRequest& rReq) case SID_SIZE_VISAREA: { - Rectangle aVisArea = mpFrameView->GetVisArea(); + ::tools::Rectangle aVisArea = mpFrameView->GetVisArea(); Size aVisAreaSize = aVisArea.GetSize(); if (aVisAreaSize.Height()!=0 && aVisAreaSize.Width()!=0) @@ -1192,9 +1192,9 @@ void DrawViewShell::FuSupport(SfxRequest& rReq) aPos.Y() -= nH / 2; if ( nW && nH ) { - SetZoomRect(Rectangle(aPos, Size(nW, nH))); + SetZoomRect(::tools::Rectangle(aPos, Size(nW, nH))); - Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( Rectangle( Point(0,0), + ::tools::Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), GetActiveWindow()->GetOutputSizePixel()) ); mpZoomList->InsertZoomRect(aVisAreaWin); } @@ -1215,7 +1215,7 @@ void DrawViewShell::FuSupport(SfxRequest& rReq) if( pPageView ) { - Rectangle aBoundRect( pPageView->GetObjList()->GetAllObjBoundRect() ); + ::tools::Rectangle aBoundRect( pPageView->GetObjList()->GetAllObjBoundRect() ); long nW = (long) (aBoundRect.GetWidth() * 1.03); long nH = (long) (aBoundRect.GetHeight() * 1.03); @@ -1224,9 +1224,9 @@ void DrawViewShell::FuSupport(SfxRequest& rReq) aPos.Y() -= nH / 2; if ( nW && nH ) { - SetZoomRect( Rectangle( aPos, Size( nW, nH ) ) ); + SetZoomRect( ::tools::Rectangle( aPos, Size( nW, nH ) ) ); - Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( Rectangle( Point(0,0), + ::tools::Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), GetActiveWindow()->GetOutputSizePixel()) ); mpZoomList->InsertZoomRect(aVisAreaWin); } @@ -1454,13 +1454,13 @@ void DrawViewShell::InsertURLField(const OUString& rURL, const OUString& rText, pOutl->SetUpdateMode( false ); Point aPos; - Rectangle aRect(aPos, GetActiveWindow()->GetOutputSizePixel() ); + ::tools::Rectangle aRect(aPos, GetActiveWindow()->GetOutputSizePixel() ); aPos = aRect.Center(); aPos = GetActiveWindow()->PixelToLogic(aPos); aPos.X() -= aSize.Width() / 2; aPos.Y() -= aSize.Height() / 2; - Rectangle aLogicRect(aPos, aSize); + ::tools::Rectangle aLogicRect(aPos, aSize); pRectObj->SetLogicRect(aLogicRect); pRectObj->SetOutlinerParaObject( pOutlParaObject ); mpDrawView->InsertObjectAtView(pRectObj, *mpDrawView->GetSdrPageView()); @@ -1544,14 +1544,14 @@ void DrawViewShell::InsertURLButton(const OUString& rURL, const OUString& rText, } else { - aPos = Rectangle(aPos, GetActiveWindow()->GetOutputSizePixel()).Center(); + aPos = ::tools::Rectangle(aPos, GetActiveWindow()->GetOutputSizePixel()).Center(); aPos = GetActiveWindow()->PixelToLogic(aPos); } Size aSize(4000, 1000); aPos.X() -= aSize.Width() / 2; aPos.Y() -= aSize.Height() / 2; - pUnoCtrl->SetLogicRect(Rectangle(aPos, aSize)); + pUnoCtrl->SetLogicRect(::tools::Rectangle(aPos, aSize)); SdrInsertFlags nOptions = SdrInsertFlags::SETDEFLAYER; diff --git a/sd/source/ui/view/drviewsh.cxx b/sd/source/ui/view/drviewsh.cxx index 2a3dd490dd6d..6fb9e8ac0576 100644 --- a/sd/source/ui/view/drviewsh.cxx +++ b/sd/source/ui/view/drviewsh.cxx @@ -58,7 +58,7 @@ void DrawViewShell::GotoBookmark(const OUString& rBookmark) |* \************************************************************************/ -void DrawViewShell::MakeVisible(const Rectangle& rRect, vcl::Window& rWin) +void DrawViewShell::MakeVisible(const ::tools::Rectangle& rRect, vcl::Window& rWin) { // tdf#98646 check if Rectangle which contains the bounds of the region to // be shown eventually contains values that cause overflows when processing @@ -87,7 +87,7 @@ void DrawViewShell::MakeVisible(const Rectangle& rRect, vcl::Window& rWin) rWin.Push(PushFlags::MAPMODE); rWin.EnableMapMode(); } - Rectangle aVisArea(rWin.PixelToLogic(Rectangle(Point(0,0), aVisSizePixel))); + ::tools::Rectangle aVisArea(rWin.PixelToLogic(::tools::Rectangle(Point(0,0), aVisSizePixel))); if (bTiledRendering) rWin.Pop(); Size aVisAreaSize(aVisArea.GetSize()); @@ -100,7 +100,7 @@ void DrawViewShell::MakeVisible(const Rectangle& rRect, vcl::Window& rWin) // allow a mode for move-only visibility without zooming. const sal_Int32 nPercentBorder(30); - const Rectangle aInnerRectangle( + const ::tools::Rectangle aInnerRectangle( aVisArea.Left() + ((aVisAreaSize.Width() * nPercentBorder) / 200), aVisArea.Top() + ((aVisAreaSize.Height() * nPercentBorder) / 200), aVisArea.Right() - ((aVisAreaSize.Width() * nPercentBorder) / 200), diff --git a/sd/source/ui/view/frmview.cxx b/sd/source/ui/view/frmview.cxx index 357623295654..df7efde02afa 100644 --- a/sd/source/ui/view/frmview.cxx +++ b/sd/source/ui/view/frmview.cxx @@ -205,7 +205,7 @@ FrameView::FrameView(SdDrawDocument* pDrawDoc, FrameView* pFrameView /* = NULK * SetActiveLayer( SD_RESSTR(STR_LAYER_LAYOUT) ); mbNoColors = true; mbNoAttribs = false; - maVisArea = Rectangle( Point(), Size(0, 0) ); + maVisArea = ::tools::Rectangle( Point(), Size(0, 0) ); mePageKind = PageKind::Standard; mePageKindOnLoad = PageKind::Standard; mnSelectedPage = 0; @@ -427,7 +427,7 @@ void FrameView::WriteUserDataSequence ( css::uno::Sequence < css::beans::Propert // aUserData.addValue( sUNO_View_EditModeHandout, makeAny( (sal_Int32)GetViewShEditMode( PageKind::Handout ) ) ); { - const Rectangle aVisArea = GetVisArea(); + const ::tools::Rectangle aVisArea = GetVisArea(); aUserData.addValue( sUNO_View_VisibleAreaTop, makeAny( (sal_Int32)aVisArea.Top() ) ); aUserData.addValue( sUNO_View_VisibleAreaLeft, makeAny( (sal_Int32)aVisArea.Left() ) ); @@ -658,7 +658,7 @@ void FrameView::ReadUserDataSequence ( const css::uno::Sequence < css::beans::Pr sal_Int32 nTop = 0; if( pValue->Value >>= nTop ) { - Rectangle aVisArea( GetVisArea() ); + ::tools::Rectangle aVisArea( GetVisArea() ); aVisArea.Bottom() += nTop - aVisArea.Top(); aVisArea.Top() = nTop; SetVisArea( aVisArea ); @@ -669,7 +669,7 @@ void FrameView::ReadUserDataSequence ( const css::uno::Sequence < css::beans::Pr sal_Int32 nLeft = 0; if( pValue->Value >>= nLeft ) { - Rectangle aVisArea( GetVisArea() ); + ::tools::Rectangle aVisArea( GetVisArea() ); aVisArea.Right() += nLeft - aVisArea.Left(); aVisArea.Left() = nLeft; SetVisArea( aVisArea ); @@ -680,7 +680,7 @@ void FrameView::ReadUserDataSequence ( const css::uno::Sequence < css::beans::Pr sal_Int32 nWidth = 0; if( pValue->Value >>= nWidth ) { - Rectangle aVisArea( GetVisArea() ); + ::tools::Rectangle aVisArea( GetVisArea() ); aVisArea.Right() = aVisArea.Left() + nWidth - 1; SetVisArea( aVisArea ); } @@ -690,7 +690,7 @@ void FrameView::ReadUserDataSequence ( const css::uno::Sequence < css::beans::Pr sal_Int32 nHeight = 0; if( pValue->Value >>= nHeight ) { - Rectangle aVisArea( GetVisArea() ); + ::tools::Rectangle aVisArea( GetVisArea() ); aVisArea.Bottom() = nHeight + aVisArea.Top() - 1; SetVisArea( aVisArea ); } diff --git a/sd/source/ui/view/outlnvs2.cxx b/sd/source/ui/view/outlnvs2.cxx index 5e7ee9db9493..fc1ac93e8383 100644 --- a/sd/source/ui/view/outlnvs2.cxx +++ b/sd/source/ui/view/outlnvs2.cxx @@ -143,7 +143,7 @@ void OutlineViewShell::FuTemporary(SfxRequest &rReq) case SID_ZOOM_OUT: { SetZoom( std::min( (long) ( GetActiveWindow()->GetZoom() * 2 ), (long) GetActiveWindow()->GetMaxZoom() ) ); - Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( Rectangle( Point(0,0), + ::tools::Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), GetActiveWindow()->GetOutputSizePixel()) ); mpZoomList->InsertZoomRect(aVisAreaWin); Invalidate( SID_ATTR_ZOOM ); @@ -157,7 +157,7 @@ void OutlineViewShell::FuTemporary(SfxRequest &rReq) case SID_SIZE_REAL: { SetZoom( 100 ); - Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( Rectangle( Point(0,0), + ::tools::Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), GetActiveWindow()->GetOutputSizePixel()) ); mpZoomList->InsertZoomRect(aVisAreaWin); Invalidate( SID_ATTR_ZOOM ); @@ -170,7 +170,7 @@ void OutlineViewShell::FuTemporary(SfxRequest &rReq) case SID_ZOOM_IN: { SetZoom( std::max( (long) ( GetActiveWindow()->GetZoom() / 2 ), (long) GetActiveWindow()->GetMinZoom() ) ); - Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( Rectangle( Point(0,0), + ::tools::Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), GetActiveWindow()->GetOutputSizePixel()) ); mpZoomList->InsertZoomRect(aVisAreaWin); Invalidate( SID_ATTR_ZOOM ); diff --git a/sd/source/ui/view/outlnvsh.cxx b/sd/source/ui/view/outlnvsh.cxx index 78400790dde2..470a7eed34bc 100644 --- a/sd/source/ui/view/outlnvsh.cxx +++ b/sd/source/ui/view/outlnvsh.cxx @@ -233,7 +233,7 @@ void OutlineViewShell::Shutdown() * Paint method: the event gets forwarded from pWindow to the Viewshell * and the current function */ -void OutlineViewShell::Paint(const Rectangle& rRect, ::sd::Window* pWin) +void OutlineViewShell::Paint(const ::tools::Rectangle& rRect, ::sd::Window* pWin) { if (pOlView) { @@ -260,14 +260,14 @@ void OutlineViewShell::ArrangeGUIElements () // change OuputArea of the OutlinerView OutlinerView* pOutlinerView = pOlView->GetViewByWindow(pWindow); - Rectangle aWin(Point(0,0), pWindow->GetOutputSizePixel()); + ::tools::Rectangle aWin(Point(0,0), pWindow->GetOutputSizePixel()); aWin = pWindow->PixelToLogic(aWin); pOutlinerView->SetOutputArea(aWin); - Rectangle aVis = pOutlinerView->GetVisArea(); + ::tools::Rectangle aVis = pOutlinerView->GetVisArea(); - Rectangle aText = Rectangle(Point(0,0), + ::tools::Rectangle aText = ::tools::Rectangle(Point(0,0), Size(pOlView->GetPaperWidth(), pOlView->GetOutliner().GetTextHeight())); if (aWin.GetHeight() > aText.Bottom()) @@ -499,7 +499,7 @@ void OutlineViewShell::FuSupport(SfxRequest &rReq) if (aDataHelper.GetTransferable().is()) { pOlView->InsertData( aDataHelper, - GetActiveWindow()->PixelToLogic( Rectangle( Point(), GetActiveWindow()->GetOutputSizePixel() ).Center() ), + GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(), GetActiveWindow()->GetOutputSizePixel() ).Center() ), nAction, false, SotClipboardFormatId::STRING); } } @@ -1129,7 +1129,7 @@ void OutlineViewShell::SetZoom(long nZoom) { // change OutputArea of OutlinerView OutlinerView* pOutlinerView = pOlView->GetViewByWindow(pWindow); - Rectangle aWin(Point(0,0), pWindow->GetOutputSizePixel()); + ::tools::Rectangle aWin(Point(0,0), pWindow->GetOutputSizePixel()); aWin = pWindow->PixelToLogic(aWin); pOutlinerView->SetOutputArea(aWin); } @@ -1141,7 +1141,7 @@ void OutlineViewShell::SetZoom(long nZoom) /** * Zoom with zoom rectangle. Inform OutlinerView */ -void OutlineViewShell::SetZoomRect(const Rectangle& rZoomRect) +void OutlineViewShell::SetZoomRect(const ::tools::Rectangle& rZoomRect) { ViewShell::SetZoomRect(rZoomRect); @@ -1150,7 +1150,7 @@ void OutlineViewShell::SetZoomRect(const Rectangle& rZoomRect) { // change OutputArea of OutlinerView OutlinerView* pOutlinerView = pOlView->GetViewByWindow(pWindow); - Rectangle aWin(Point(0,0), pWindow->GetOutputSizePixel()); + ::tools::Rectangle aWin(Point(0,0), pWindow->GetOutputSizePixel()); aWin = pWindow->PixelToLogic(aWin); pOutlinerView->SetOutputArea(aWin); } @@ -1822,7 +1822,7 @@ void OutlineViewShell::ReadUserDataSequence ( const css::uno::Sequence < css::be ReadFrameViewData( mpFrameView ); } -void OutlineViewShell::VisAreaChanged(const Rectangle& rRect) +void OutlineViewShell::VisAreaChanged(const ::tools::Rectangle& rRect) { ViewShell::VisAreaChanged( rRect ); diff --git a/sd/source/ui/view/outlview.cxx b/sd/source/ui/view/outlview.cxx index 723e5ff0e5e0..ac3ebfc5d973 100644 --- a/sd/source/ui/view/outlview.cxx +++ b/sd/source/ui/view/outlview.cxx @@ -114,7 +114,7 @@ OutlineView::OutlineView( DrawDocShell& rDocSh, vcl::Window* pWindow, OutlineVie } mpOutlinerView[0] = new OutlinerView(&mrOutliner, pWindow); - Rectangle aNullRect; + ::tools::Rectangle aNullRect; mpOutlinerView[0]->SetOutputArea(aNullRect); mrOutliner.SetUpdateMode(false); mrOutliner.InsertView(mpOutlinerView[0], EE_APPEND); @@ -213,7 +213,7 @@ void OutlineView::DisconnectFromApplication() Application::RemoveEventListener(LINK(this, OutlineView, AppEventListenerHdl)); } -void OutlineView::Paint(const Rectangle& rRect, ::sd::Window* pWin) +void OutlineView::Paint(const ::tools::Rectangle& rRect, ::sd::Window* pWin) { OutlinerView* pOlView = GetViewByWindow(pWin); @@ -232,7 +232,7 @@ void OutlineView::AddWindowToPaintView(OutputDevice* pWin, vcl::Window* pWindow) { bool bAdded = false; bool bValidArea = false; - Rectangle aOutputArea; + ::tools::Rectangle aOutputArea; const Color aWhiteColor( COL_WHITE ); sal_uInt16 nView = 0; @@ -770,11 +770,11 @@ IMPL_LINK_NOARG(OutlineView, StatusEventHdl, EditStatus&, void) { ::sd::Window* pWin = mrOutlineViewShell.GetActiveWindow(); OutlinerView* pOutlinerView = GetViewByWindow(pWin); - Rectangle aVis = pOutlinerView->GetVisArea(); - Rectangle aText = Rectangle(Point(0,0), + ::tools::Rectangle aVis = pOutlinerView->GetVisArea(); + ::tools::Rectangle aText = ::tools::Rectangle(Point(0,0), Size(mnPaperWidth, mrOutliner.GetTextHeight())); - Rectangle aWin(Point(0,0), pWin->GetOutputSizePixel()); + ::tools::Rectangle aWin(Point(0,0), pWin->GetOutputSizePixel()); aWin = pWin->PixelToLogic(aWin); if (!aVis.IsEmpty()) // not when opening diff --git a/sd/source/ui/view/presvish.cxx b/sd/source/ui/view/presvish.cxx index 7d78cddacbcc..a9c63d886caf 100644 --- a/sd/source/ui/view/presvish.cxx +++ b/sd/source/ui/view/presvish.cxx @@ -140,7 +140,7 @@ void PresentationViewShell::Activate( bool bIsMDIActivate ) GetDocSh()->Connect( this ); } -void PresentationViewShell::Paint( const Rectangle& rRect, ::sd::Window* ) +void PresentationViewShell::Paint( const ::tools::Rectangle& rRect, ::sd::Window* ) { rtl::Reference< SlideShow > xSlideShow( SlideShow::GetSlideShow( GetViewShellBase() ) ); if( xSlideShow.is() ) diff --git a/sd/source/ui/view/sdview.cxx b/sd/source/ui/view/sdview.cxx index 34d3ae3cf4bc..2856afa6355c 100644 --- a/sd/source/ui/view/sdview.cxx +++ b/sd/source/ui/view/sdview.cxx @@ -707,7 +707,7 @@ bool View::SdrBeginTextEdit( { if (OutlinerView* pView = GetTextEditOutlinerView()) { - Rectangle aRectangle = pView->GetOutputArea(); + ::tools::Rectangle aRectangle = pView->GetOutputArea(); if (pWin && pWin->GetMapMode().GetMapUnit() == MapUnit::Map100thMM) aRectangle = OutputDevice::LogicToLogic(aRectangle, MapUnit::Map100thMM, MapUnit::MapTwip); OString sRectangle = aRectangle.toString(); @@ -894,7 +894,7 @@ void View::SetMarkedOriginalSize() if ( bOK ) { - Rectangle aDrawRect( pObj->GetLogicRect() ); + ::tools::Rectangle aDrawRect( pObj->GetLogicRect() ); pUndoGroup->AddAction( mrDoc.GetSdrUndoFactory().CreateUndoGeoObject( *pObj ) ); pObj->Resize( aDrawRect.TopLeft(), Fraction( aOleSize.Width(), aDrawRect.GetWidth() ), @@ -907,7 +907,7 @@ void View::SetMarkedOriginalSize() const SdrGrafObj* pSdrGrafObj = static_cast< const SdrGrafObj* >(pObj); const Size aSize = pSdrGrafObj->getOriginalSize( ); pUndoGroup->AddAction( GetModel()->GetSdrUndoFactory().CreateUndoGeoObject(*pObj ) ); - Rectangle aRect( pObj->GetLogicRect() ); + ::tools::Rectangle aRect( pObj->GetLogicRect() ); aRect.SetSize( aSize ); pObj->SetLogicRect( aRect ); bOK = true; @@ -939,7 +939,7 @@ void View::DoConnect(SdrOle2Obj* pObj) if ( !pSdClient ) { pSdClient = new Client(pObj, mpViewSh, pWindow); - Rectangle aRect = pObj->GetLogicRect(); + ::tools::Rectangle aRect = pObj->GetLogicRect(); { // TODO/LEAN: working with visual area can switch object to running state Size aDrawSize = aRect.GetSize(); @@ -1177,7 +1177,7 @@ bool View::MarkPoint(SdrHdl& rHdl, bool bUnmark ) return FmFormView::MarkPoint( rHdl, bUnmark ); } -bool View::MarkPoints(const Rectangle* pRect, bool bUnmark) +bool View::MarkPoints(const ::tools::Rectangle* pRect, bool bUnmark) { if( maSmartTags.MarkPoints( pRect, bUnmark ) ) return true; diff --git a/sd/source/ui/view/sdview2.cxx b/sd/source/ui/view/sdview2.cxx index 0b1cab132db3..c6e7721fd303 100644 --- a/sd/source/ui/view/sdview2.cxx +++ b/sd/source/ui/view/sdview2.cxx @@ -99,7 +99,7 @@ css::uno::Reference< css::datatransfer::XTransferable > View::CreateClipboardDat // #112978# need to use GetAllMarkedBoundRect instead of GetAllMarkedRect to get // fat lines correctly - const Rectangle aMarkRect( GetAllMarkedBoundRect() ); + const ::tools::Rectangle aMarkRect( GetAllMarkedBoundRect() ); TransferableObjectDescriptor aObjDesc; SdrOle2Obj* pSdrOleObj = nullptr; SdrPageView* pPgView = GetSdrPageView(); @@ -200,7 +200,7 @@ css::uno::Reference< css::datatransfer::XTransferable > View::CreateSelectionDat SdTransferable* pTransferable = new SdTransferable( &mrDoc, pWorkView, true ); css::uno::Reference< css::datatransfer::XTransferable > xRet( pTransferable ); TransferableObjectDescriptor aObjDesc; - const Rectangle aMarkRect( GetAllMarkedRect() ); + const ::tools::Rectangle aMarkRect( GetAllMarkedRect() ); OUString aDisplayName; SD_MOD()->pTransferSelection = pTransferable; @@ -319,7 +319,7 @@ void View::DoPaste (vcl::Window* pWindow) sal_Int8 nDnDAction = DND_ACTION_COPY; if( pWindow ) - aPos = pWindow->PixelToLogic( Rectangle( aPos, pWindow->GetOutputSizePixel() ).Center() ); + aPos = pWindow->PixelToLogic( ::tools::Rectangle( aPos, pWindow->GetOutputSizePixel() ).Center() ); DrawViewShell* pDrViewSh = static_cast<DrawViewShell*>( mpDocSh->GetViewShell() ); @@ -458,7 +458,7 @@ sal_Int8 View::AcceptDrop( const AcceptDropEvent& rEvt, DropTargetHelper& rTarge if( pOLV ) { - Rectangle aRect( pOLV->GetOutputArea() ); + ::tools::Rectangle aRect( pOLV->GetOutputArea() ); if (GetMarkedObjectCount() == 1) { @@ -636,7 +636,7 @@ sal_Int8 View::ExecuteDrop( const ExecuteDropEvent& rEvt, if( pOLV ) { - Rectangle aRect( pOLV->GetOutputArea() ); + ::tools::Rectangle aRect( pOLV->GetOutputArea() ); if( GetMarkedObjectCount() == 1 ) { diff --git a/sd/source/ui/view/sdview3.cxx b/sd/source/ui/view/sdview3.cxx index e6fadb143d45..9ae250f5ad36 100644 --- a/sd/source/ui/view/sdview3.cxx +++ b/sd/source/ui/view/sdview3.cxx @@ -114,11 +114,11 @@ SdrObject* ImpGetClone(std::vector<ImpRememberOrigAndClone*>& aConnectorContaine } // restrict movement to WorkArea -void ImpCheckInsertPos(Point& rPos, const Size& rSize, const Rectangle& rWorkArea) +void ImpCheckInsertPos(Point& rPos, const Size& rSize, const ::tools::Rectangle& rWorkArea) { if(!rWorkArea.IsEmpty()) { - Rectangle aMarkRect(Point(rPos.X() - (rSize.Width() / 2), rPos.Y() - (rSize.Height() / 2)), rSize); + ::tools::Rectangle aMarkRect(Point(rPos.X() - (rSize.Width() / 2), rPos.Y() - (rSize.Height() / 2)), rSize); if(!aMarkRect.IsInside(rWorkArea)) { @@ -465,7 +465,7 @@ bool View::InsertData( const TransferableDataHelper& rDataHelper, // source objects, if necessary (#103207) if( pOwnData == SD_MOD()->pTransferSelection ) { - Rectangle aCurBoundRect; + ::tools::Rectangle aCurBoundRect; if( pMarkList->TakeBoundRect( pPV, aCurBoundRect ) ) aCurPos = aCurBoundRect.TopLeft(); @@ -715,10 +715,10 @@ bool View::InsertData( const TransferableDataHelper& rDataHelper, { // replace object SdrObject* pNewObj = pObj->Clone(); - Rectangle aPickObjRect( pPickObj2->GetCurrentBoundRect() ); + ::tools::Rectangle aPickObjRect( pPickObj2->GetCurrentBoundRect() ); Size aPickObjSize( aPickObjRect.GetSize() ); Point aVec( aPickObjRect.TopLeft() ); - Rectangle aObjRect( pNewObj->GetCurrentBoundRect() ); + ::tools::Rectangle aObjRect( pNewObj->GetCurrentBoundRect() ); Size aObjSize( aObjRect.GetSize() ); Fraction aScaleWidth( aPickObjSize.Width(), aObjSize.Width() ); @@ -841,7 +841,7 @@ bool View::InsertData( const TransferableDataHelper& rDataHelper, if( pObj ) { - Rectangle aRect( pObj->GetLogicRect() ); + ::tools::Rectangle aRect( pObj->GetLogicRect() ); Size aSize( aRect.GetSize() ); maDropPos.X() -= ( aSize.Width() >> 1 ); @@ -994,7 +994,7 @@ bool View::InsertData( const TransferableDataHelper& rDataHelper, maDropPos.X() -= std::min( aSize.Width(), aMaxSize.Width() ) >> 1; maDropPos.Y() -= std::min( aSize.Height(), aMaxSize.Height() ) >> 1; - Rectangle aRect( maDropPos, aSize ); + ::tools::Rectangle aRect( maDropPos, aSize ); SdrOle2Obj* pObj = new SdrOle2Obj( aObjRef, aName, aRect ); SdrPageView* pPV = GetSdrPageView(); SdrInsertFlags nOptions = SdrInsertFlags::SETDEFLAYER; @@ -1164,7 +1164,7 @@ bool View::InsertData( const TransferableDataHelper& rDataHelper, maDropPos.X() -= std::min( aSize.Width(), aMaxSize.Width() ) >> 1; maDropPos.Y() -= std::min( aSize.Height(), aMaxSize.Height() ) >> 1; - Rectangle aRect( maDropPos, aSize ); + ::tools::Rectangle aRect( maDropPos, aSize ); SdrOle2Obj* pObj = new SdrOle2Obj( aObjRef, aName, aRect ); SdrPageView* pPV = GetSdrPageView(); SdrInsertFlags nOptions = SdrInsertFlags::SETDEFLAYER; @@ -1404,7 +1404,7 @@ bool View::InsertData( const TransferableDataHelper& rDataHelper, if( pOLV ) { - Rectangle aRect( pOLV->GetOutputArea() ); + ::tools::Rectangle aRect( pOLV->GetOutputArea() ); Point aPos( pOLV->GetWindow()->PixelToLogic( maDropPos ) ); if( aRect.IsInside( aPos ) || ( !bDrag && IsTextEdit() ) ) @@ -1440,7 +1440,7 @@ bool View::InsertData( const TransferableDataHelper& rDataHelper, if( pOLV ) { - Rectangle aRect( pOLV->GetOutputArea() ); + ::tools::Rectangle aRect( pOLV->GetOutputArea() ); Point aPos( pOLV->GetWindow()->PixelToLogic( maDropPos ) ); if( aRect.IsInside( aPos ) || ( !bDrag && IsTextEdit() ) ) diff --git a/sd/source/ui/view/sdview4.cxx b/sd/source/ui/view/sdview4.cxx index 060760ce4948..972ec47696a9 100644 --- a/sd/source/ui/view/sdview4.cxx +++ b/sd/source/ui/view/sdview4.cxx @@ -125,7 +125,7 @@ SdrGrafObj* View::InsertGraphic( const Graphic& rGraphic, sal_Int8& rAction, if ( pNewGrafObj->IsEmptyPresObj() ) { - Rectangle aRect( pNewGrafObj->GetLogicRect() ); + ::tools::Rectangle aRect( pNewGrafObj->GetLogicRect() ); pNewGrafObj->AdjustToMaxRect( aRect ); pNewGrafObj->SetOutlinerParaObject(nullptr); pNewGrafObj->SetEmptyPresObj(false); @@ -192,12 +192,12 @@ SdrGrafObj* View::InsertGraphic( const Graphic& rGraphic, sal_Int8& rAction, MapMode( MapUnit::Map100thMM ) ); } - pNewGrafObj = new SdrGrafObj( rGraphic, Rectangle( rPos, aSize ) ); + pNewGrafObj = new SdrGrafObj( rGraphic, ::tools::Rectangle( rPos, aSize ) ); SdrPage* pPage = pPV->GetPage(); Size aPageSize( pPage->GetSize() ); aPageSize.Width() -= pPage->GetLftBorder() + pPage->GetRgtBorder(); aPageSize.Height() -= pPage->GetUppBorder() + pPage->GetLwrBorder(); - pNewGrafObj->AdjustToMaxRect( Rectangle( Point(), aPageSize ), true ); + pNewGrafObj->AdjustToMaxRect( ::tools::Rectangle( Point(), aPageSize ), true ); SdrInsertFlags nOptions = SdrInsertFlags::SETDEFLAYER; bool bIsPresTarget = false; @@ -223,9 +223,9 @@ SdrGrafObj* View::InsertGraphic( const Graphic& rGraphic, sal_Int8& rAction, if (pImageMap) pNewGrafObj->AppendUserData(new SdIMapInfo(*pImageMap)); - Rectangle aPickObjRect(pPickObj->GetCurrentBoundRect()); + ::tools::Rectangle aPickObjRect(pPickObj->GetCurrentBoundRect()); Size aPickObjSize(aPickObjRect.GetSize()); - Rectangle aObjRect(pNewGrafObj->GetCurrentBoundRect()); + ::tools::Rectangle aObjRect(pNewGrafObj->GetCurrentBoundRect()); Size aObjSize(aObjRect.GetSize()); Fraction aScaleWidth(aPickObjSize.Width(), aObjSize.Width()); @@ -340,7 +340,7 @@ SdrMediaObj* View::InsertMediaObj( const OUString& rMediaURL, const OUString& rM } else if( pPV ) { - Rectangle aRect( rPos, rSize ); + ::tools::Rectangle aRect( rPos, rSize ); if( pPickObj ) aRect = pPickObj->GetLogicRect(); @@ -528,7 +528,7 @@ IMPL_LINK_NOARG(View, DropInsertFileHdl, Timer *, void) } Size aSize( aSz.Width, aSz.Height ); - Rectangle aRect; + ::tools::Rectangle aRect; if (!aSize.Width() || !aSize.Height()) { @@ -536,7 +536,7 @@ IMPL_LINK_NOARG(View, DropInsertFileHdl, Timer *, void) aSize.Height() = 1000; } - aRect = Rectangle( maDropPos, aSize ); + aRect = ::tools::Rectangle( maDropPos, aSize ); SdrOle2Obj* pOleObj = new SdrOle2Obj( svt::EmbeddedObjectRef( xObj, nAspect ), aName, aRect ); SdrInsertFlags nOptions = SdrInsertFlags::SETDEFLAYER; diff --git a/sd/source/ui/view/sdwindow.cxx b/sd/source/ui/view/sdwindow.cxx index b6fc0dafa2ae..9d13093e6144 100644 --- a/sd/source/ui/view/sdwindow.cxx +++ b/sd/source/ui/view/sdwindow.cxx @@ -214,7 +214,7 @@ void Window::PrePaint(vcl::RenderContext& /*rRenderContext*/) mpViewShell->PrePaint(); } -void Window::Paint(vcl::RenderContext& /*rRenderContext*/, const Rectangle& rRect) +void Window::Paint(vcl::RenderContext& /*rRenderContext*/, const ::tools::Rectangle& rRect) { if ( mpViewShell ) mpViewShell->Paint(rRect, this); @@ -386,7 +386,7 @@ void Window::SetZoomIntegral(long nZoom) SetZoomFactor(nZoom); } -long Window::GetZoomForRect( const Rectangle& rZoomRect ) +long Window::GetZoomForRect( const ::tools::Rectangle& rZoomRect ) { long nRetZoom = 100; @@ -445,7 +445,7 @@ long Window::GetZoomForRect( const Rectangle& rZoomRect ) is displayed centered and as large as possible while still being fully visible in the window. */ -long Window::SetZoomRect (const Rectangle& rZoomRect) +long Window::SetZoomRect (const ::tools::Rectangle& rZoomRect) { long nNewZoom = 100; @@ -996,7 +996,7 @@ Selection Window::GetSurroundingTextSelection() const } } -void Window::LogicInvalidate(const Rectangle* pRectangle) +void Window::LogicInvalidate(const ::tools::Rectangle* pRectangle) { DrawViewShell* pDrawViewShell = dynamic_cast<DrawViewShell*>(mpViewShell); if (pDrawViewShell && pDrawViewShell->IsInSwitchPage()) @@ -1007,7 +1007,7 @@ void Window::LogicInvalidate(const Rectangle* pRectangle) sRectangle = "EMPTY"; else { - Rectangle aRectangle(*pRectangle); + ::tools::Rectangle aRectangle(*pRectangle); if (GetMapMode().GetMapUnit() == MapUnit::Map100thMM) aRectangle = OutputDevice::LogicToLogic(aRectangle, MapUnit::Map100thMM, MapUnit::MapTwip); sRectangle = aRectangle.toString(); diff --git a/sd/source/ui/view/viewoverlaymanager.cxx b/sd/source/ui/view/viewoverlaymanager.cxx index 476593a36f64..44aa1f59e3d0 100644 --- a/sd/source/ui/view/viewoverlaymanager.cxx +++ b/sd/source/ui/view/viewoverlaymanager.cxx @@ -190,7 +190,7 @@ void ImageButtonHdl::onMouseEnter(const MouseEvent& rMEvt) aResId.SetRT( RSC_STRING ); OUString aHelpText( aResId ); - Rectangle aScreenRect( pDev->LogicToPixel( GetPos() ), maImageSize ); + ::tools::Rectangle aScreenRect( pDev->LogicToPixel( GetPos() ), maImageSize ); Help::ShowQuickHelp(static_cast< vcl::Window* >( pHdlList->GetView()->GetFirstOutputDevice() ), aScreenRect, aHelpText); } Touch(); @@ -319,7 +319,7 @@ BitmapEx ChangePlaceholderTag::createOverlayImage( int nHighlight ) { SdrObject* pPlaceholder = mxPlaceholderObj.get(); SmartTagReference xThis( this ); - const Rectangle& rSnapRect = pPlaceholder->GetSnapRect(); + const ::tools::Rectangle& rSnapRect = pPlaceholder->GetSnapRect(); OutputDevice* pDev = mrView.GetFirstOutputDevice(); if( pDev == nullptr ) @@ -334,14 +334,14 @@ BitmapEx ChangePlaceholderTag::createOverlayImage( int nHighlight ) aRet.SetSizePixel( Size( aSize.Width() << 1, aSize.Height() << 1 ) ); - const Rectangle aRectSrc( Point( 0, 0 ), aSize ); + const ::tools::Rectangle aRectSrc( Point( 0, 0 ), aSize ); aRet = *(getButtonImage((nHighlight == 0) ? 4 : 0, bLarge)); aRet.Expand( aSize.Width(), aSize.Height(), true ); - aRet.CopyPixel( Rectangle( Point( aSize.Width(), 0 ), aSize ), aRectSrc, getButtonImage((nHighlight == 1) ? 5 : 1, bLarge) ); - aRet.CopyPixel( Rectangle( Point( 0, aSize.Height() ), aSize ), aRectSrc, getButtonImage((nHighlight == 2) ? 6 : 2, bLarge) ); - aRet.CopyPixel( Rectangle( Point( aSize.Width(), aSize.Height() ), aSize ), aRectSrc, getButtonImage((nHighlight == 3) ? 7 : 3, bLarge) ); + aRet.CopyPixel( ::tools::Rectangle( Point( aSize.Width(), 0 ), aSize ), aRectSrc, getButtonImage((nHighlight == 1) ? 5 : 1, bLarge) ); + aRet.CopyPixel( ::tools::Rectangle( Point( 0, aSize.Height() ), aSize ), aRectSrc, getButtonImage((nHighlight == 2) ? 6 : 2, bLarge) ); + aRet.CopyPixel( ::tools::Rectangle( Point( aSize.Width(), aSize.Height() ), aSize ), aRectSrc, getButtonImage((nHighlight == 3) ? 7 : 3, bLarge) ); } return aRet; @@ -353,7 +353,7 @@ void ChangePlaceholderTag::addCustomHandles( SdrHdlList& rHandlerList ) { SdrObject* pPlaceholder = mxPlaceholderObj.get(); SmartTagReference xThis( this ); - const Rectangle& rSnapRect = pPlaceholder->GetSnapRect(); + const ::tools::Rectangle& rSnapRect = pPlaceholder->GetSnapRect(); const Point aPoint; OutputDevice* pDev = mrView.GetFirstOutputDevice(); diff --git a/sd/source/ui/view/viewshe2.cxx b/sd/source/ui/view/viewshe2.cxx index e556e5ef2f2c..c59680375463 100644 --- a/sd/source/ui/view/viewshe2.cxx +++ b/sd/source/ui/view/viewshe2.cxx @@ -162,13 +162,13 @@ void ViewShell::VirtHScrollHdl(ScrollBar* pHScroll) mpContentWindow->SetVisibleXY(fX, -1); - Rectangle aVisArea = GetDocSh()->GetVisArea(ASPECT_CONTENT); + ::tools::Rectangle aVisArea = GetDocSh()->GetVisArea(ASPECT_CONTENT); Point aVisAreaPos = GetActiveWindow()->PixelToLogic( Point(0,0) ); aVisArea.SetPos(aVisAreaPos); GetDocSh()->SetVisArea(aVisArea); Size aVisSizePixel = GetActiveWindow()->GetOutputSizePixel(); - Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( Rectangle( Point(0,0), aVisSizePixel) ); + ::tools::Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), aVisSizePixel) ); VisAreaChanged(aVisAreaWin); if (pView) @@ -221,13 +221,13 @@ void ViewShell::VirtVScrollHdl(ScrollBar* pVScroll) mpContentWindow->SetVisibleXY(-1, fY); - Rectangle aVisArea = GetDocSh()->GetVisArea(ASPECT_CONTENT); + ::tools::Rectangle aVisArea = GetDocSh()->GetVisArea(ASPECT_CONTENT); Point aVisAreaPos = GetActiveWindow()->PixelToLogic( Point(0,0) ); aVisArea.SetPos(aVisAreaPos); GetDocSh()->SetVisArea(aVisArea); Size aVisSizePixel = GetActiveWindow()->GetOutputSizePixel(); - Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( Rectangle( Point(0,0), aVisSizePixel) ); + ::tools::Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), aVisSizePixel) ); VisAreaChanged(aVisAreaWin); if (pView) @@ -299,13 +299,13 @@ void ViewShell::Scroll(long nScrollX, long nScrollY) GetActiveWindow()->SetVisibleXY(fX, fY); - Rectangle aVisArea = GetDocSh()->GetVisArea(ASPECT_CONTENT); + ::tools::Rectangle aVisArea = GetDocSh()->GetVisArea(ASPECT_CONTENT); Point aVisAreaPos = GetActiveWindow()->PixelToLogic( Point(0,0) ); aVisArea.SetPos(aVisAreaPos); GetDocSh()->SetVisArea(aVisArea); Size aVisSizePixel = GetActiveWindow()->GetOutputSizePixel(); - Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( Rectangle( Point(0,0), aVisSizePixel) ); + ::tools::Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), aVisSizePixel) ); VisAreaChanged(aVisAreaWin); ::sd::View* pView = GetView(); @@ -347,7 +347,7 @@ void ViewShell::SetZoom(long nZoom) } Size aVisSizePixel = GetActiveWindow()->GetOutputSizePixel(); - Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( Rectangle( Point(0,0), aVisSizePixel) ); + ::tools::Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), aVisSizePixel) ); VisAreaChanged(aVisAreaWin); ::sd::View* pView = GetView(); @@ -373,7 +373,7 @@ long ViewShell::GetZoom() const * Set zoom rectangle for active window. Sets all split windows to the same zoom * factor. */ -void ViewShell::SetZoomRect(const Rectangle& rZoomRect) +void ViewShell::SetZoomRect(const ::tools::Rectangle& rZoomRect) { long nZoom = GetActiveWindow()->SetZoomRect(rZoomRect); Fraction aUIScale(nZoom, 100); @@ -403,7 +403,7 @@ void ViewShell::SetZoomRect(const Rectangle& rZoomRect) } Size aVisSizePixel = GetActiveWindow()->GetOutputSizePixel(); - Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( Rectangle( Point(0,0), aVisSizePixel) ); + ::tools::Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), aVisSizePixel) ); VisAreaChanged(aVisAreaWin); ::sd::View* pView = GetView(); @@ -435,7 +435,7 @@ void ViewShell::InitWindows(const Point& rViewOrigin, const Size& rViewSize, } Size aVisSizePixel = GetActiveWindow()->GetOutputSizePixel(); - Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( Rectangle( Point(0,0), aVisSizePixel) ); + ::tools::Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), aVisSizePixel) ); VisAreaChanged(aVisAreaWin); ::sd::View* pView = GetView(); @@ -457,7 +457,7 @@ void ViewShell::InvalidateWindows() /** * Draw a selection rectangle with the ?provided pen on all split windows. */ -void ViewShell::DrawMarkRect(const Rectangle& rRect) const +void ViewShell::DrawMarkRect(const ::tools::Rectangle& rRect) const { if (mpContentWindow.get() != nullptr) { @@ -507,7 +507,7 @@ void ViewShell::SetPageSizeAndBorder(PageKind ePageKind, const Size& rNewSize, if (rNewSize.Width() > 0 || nLeft >= 0 || nRight >= 0 || nUpper >= 0 || nLower >= 0) { - Rectangle aNewBorderRect(nLeft, nUpper, nRight, nLower); + ::tools::Rectangle aNewBorderRect(nLeft, nUpper, nRight, nLower); pPage->ScaleObjects(rNewSize, aNewBorderRect, bScaleAll); if (rNewSize.Width() > 0) @@ -555,7 +555,7 @@ void ViewShell::SetPageSizeAndBorder(PageKind ePageKind, const Size& rNewSize, if (rNewSize.Width() > 0 || nLeft >= 0 || nRight >= 0 || nUpper >= 0 || nLower >= 0) { - Rectangle aNewBorderRect(nLeft, nUpper, nRight, nLower); + ::tools::Rectangle aNewBorderRect(nLeft, nUpper, nRight, nLower); pPage->ScaleObjects(rNewSize, aNewBorderRect, bScaleAll); if (rNewSize.Width() > 0) @@ -606,7 +606,7 @@ void ViewShell::SetPageSizeAndBorder(PageKind ePageKind, const Size& rNewSize, ::sd::View* pView = GetView(); if (pView) { - pView->SetWorkArea(Rectangle(Point() - aVisAreaPos - aPageOrg, aViewSize)); + pView->SetWorkArea(::tools::Rectangle(Point() - aVisAreaPos - aPageOrg, aViewSize)); } UpdateScrollBars(); @@ -794,7 +794,7 @@ bool ViewShell::ActivateObject(SdrOle2Obj* pObj, long nVerb) pObj->SetObjRef(xObj); } - Rectangle aRect = pObj->GetLogicRect(); + ::tools::Rectangle aRect = pObj->GetLogicRect(); if ( pObj->GetAspect() != embed::Aspects::MSOLE_ICON ) { @@ -832,12 +832,12 @@ bool ViewShell::ActivateObject(SdrOle2Obj* pObj, long nVerb) pSdClient = new Client(pObj, this, GetActiveWindow()); } - Rectangle aRect = pObj->GetLogicRect(); + ::tools::Rectangle aRect = pObj->GetLogicRect(); { // #i118485# center on BoundRect for activation, // OLE may be sheared/rotated now - const Rectangle& rBoundRect = pObj->GetCurrentBoundRect(); + const ::tools::Rectangle& rBoundRect = pObj->GetCurrentBoundRect(); const Point aDelta(rBoundRect.Center() - aRect.Center()); aRect.Move(aDelta.X(), aDelta.Y()); } @@ -883,7 +883,7 @@ bool ViewShell::ActivateObject(SdrOle2Obj* pObj, long nVerb) /** * @returns enclosing rectangle of all (split-) windows. */ -const Rectangle& ViewShell::GetAllWindowRect() +const ::tools::Rectangle& ViewShell::GetAllWindowRect() { maAllWindowRectangle.SetPos( mpContentWindow->OutputToScreenPixel(Point(0,0))); @@ -984,7 +984,7 @@ void ViewShell::ReadUserDataSequence ( const css::uno::Sequence < css::beans::Pr mpFrameView->ReadUserDataSequence( rSequence, bBrowse ); } -void ViewShell::VisAreaChanged(const Rectangle& rRect) +void ViewShell::VisAreaChanged(const ::tools::Rectangle& rRect) { OSL_ASSERT (GetViewShell()!=nullptr); GetViewShell()->VisAreaChanged(rRect); @@ -1009,7 +1009,7 @@ void ViewShell::SetWinViewPos(const Point& rWinPos) UpdateScrollBars(); Size aVisSizePixel = GetActiveWindow()->GetOutputSizePixel(); - Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( Rectangle( Point(0,0), aVisSizePixel) ); + ::tools::Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), aVisSizePixel) ); VisAreaChanged(aVisAreaWin); ::sd::View* pView = GetView(); diff --git a/sd/source/ui/view/viewshel.cxx b/sd/source/ui/view/viewshel.cxx index c509e0b547e4..97b709768cb4 100644 --- a/sd/source/ui/view/viewshel.cxx +++ b/sd/source/ui/view/viewshel.cxx @@ -1088,7 +1088,7 @@ void ViewShell::ArrangeGUIElements() } // Windows in the center and rulers at the left and top side. - maAllWindowRectangle = Rectangle( + maAllWindowRectangle = ::tools::Rectangle( maViewPos, Size(maViewSize.Width()-maScrBarWH.Width(), maViewSize.Height()-maScrBarWH.Height())); @@ -1525,7 +1525,7 @@ void ViewShell::PrePaint() { } -void ViewShell::Paint (const Rectangle&, ::sd::Window* ) +void ViewShell::Paint (const ::tools::Rectangle&, ::sd::Window* ) { } diff --git a/sd/source/ui/view/zoomlist.cxx b/sd/source/ui/view/zoomlist.cxx index d4428537e469..f2e30ea8e5a9 100644 --- a/sd/source/ui/view/zoomlist.cxx +++ b/sd/source/ui/view/zoomlist.cxx @@ -36,7 +36,7 @@ ZoomList::ZoomList(ViewShell* pViewShell) { } -void ZoomList::InsertZoomRect(const Rectangle& rRect) +void ZoomList::InsertZoomRect(const ::tools::Rectangle& rRect) { size_t nRectCount = maRectangles.size(); @@ -54,7 +54,7 @@ void ZoomList::InsertZoomRect(const Rectangle& rRect) rBindings.Invalidate( SID_ZOOM_PREV ); } -Rectangle ZoomList::GetNextZoomRect() +::tools::Rectangle ZoomList::GetNextZoomRect() { mnCurPos++; size_t nRectCount = maRectangles.size(); @@ -69,7 +69,7 @@ Rectangle ZoomList::GetNextZoomRect() return maRectangles[mnCurPos]; } -Rectangle ZoomList::GetPreviousZoomRect() +::tools::Rectangle ZoomList::GetPreviousZoomRect() { if (mnCurPos > 0) mnCurPos--; |