diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2017-03-30 20:27:55 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2017-03-31 06:27:11 +0000 |
commit | a5a571307fb3306b74ab46b085cde6388270a770 (patch) | |
tree | 66d4ce12bb5236c50ab6a5d253bc8c6d8b5d292d /cui | |
parent | 17d821af6bb9df93569836a92f6bed975587fc6c (diff) |
tdf#82580 tools: rename Rectangle to tools::Rectangle
Mostly generated using
make check COMPILER_EXTERNAL_TOOL=1 CCACHE_PREFIX=clang-rename-wrapper RENAME_ARGS="-qualified-name=Rectangle -new-name=tools::Rectangle"
Except some modules have their own foo::tools namespace, so there have
to use ::tools::Rectangle. This commit just moves the class from the
global namespace, it does not update pre/postwin.h yet.
Change-Id: I42b2de3c6f769fcf28cfe086f98eb31e42a305f2
Reviewed-on: https://gerrit.libreoffice.org/35923
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
Tested-by: Jenkins <ci@libreoffice.org>
Diffstat (limited to 'cui')
28 files changed, 78 insertions, 78 deletions
diff --git a/cui/source/customize/acccfg.cxx b/cui/source/customize/acccfg.cxx index 39172a819517..93d36283ed52 100644 --- a/cui/source/customize/acccfg.cxx +++ b/cui/source/customize/acccfg.cxx @@ -1097,7 +1097,7 @@ IMPL_LINK_NOARG(SfxAcceleratorConfigPage, RemoveHdl, Button*, void) IMPL_LINK( SfxAcceleratorConfigPage, SelectHdl, SvTreeListBox*, pListBox, void ) { // disable help - Help::ShowBalloon( this, Point(), Rectangle(), OUString() ); + Help::ShowBalloon( this, Point(), ::tools::Rectangle(), OUString() ); if (pListBox == m_pEntriesBox) { sal_uLong nPos = SvTreeList::GetRelPos( m_pEntriesBox->FirstSelected() ); diff --git a/cui/source/customize/cfg.cxx b/cui/source/customize/cfg.cxx index 0f47c1856b3a..c8410db79857 100644 --- a/cui/source/customize/cfg.cxx +++ b/cui/source/customize/cfg.cxx @@ -1573,7 +1573,7 @@ public: long n = 0; while (n <= nHalfSize) { - rRenderContext.DrawRect(Rectangle(nX + n, nY + n, nX + n, nY + nSize - n)); + rRenderContext.DrawRect(::tools::Rectangle(nX + n, nY + n, nX + n, nY + nSize - n)); ++n; } @@ -4849,7 +4849,7 @@ Image SvxToolbarEntriesListBox::GetSizedImage( Point aPos( nPosX > 0 ? nPosX : 0, nPosY > 0 ? nPosY : 0 ); rVDev.SetFillColor( aFillColor ); rVDev.SetLineColor( aFillColor ); - rVDev.DrawRect( Rectangle( Point(), aNewSize )); + rVDev.DrawRect( ::tools::Rectangle( Point(), aNewSize )); rVDev.DrawImage( aPos, aImage ); // Draw separator line 2 pixels left from the right border diff --git a/cui/source/customize/selector.cxx b/cui/source/customize/selector.cxx index 874384694521..0a22e09e8c84 100644 --- a/cui/source/customize/selector.cxx +++ b/cui/source/customize/selector.cxx @@ -122,7 +122,7 @@ void SvxConfigFunctionListBox::MouseMove( const MouseEvent& rMEvt ) aTimer.Start(); else { - Rectangle aRect(GetPosPixel(), GetSizePixel()); + ::tools::Rectangle aRect(GetPosPixel(), GetSizePixel()); Help::ShowBalloon( this, aMousePos, aRect, OUString() ); aTimer.Stop(); } @@ -136,7 +136,7 @@ IMPL_LINK_NOARG(SvxConfigFunctionListBox, TimerHdl, Timer *, void) SvTreeListEntry *pEntry = GetCurEntry(); if ( pEntry && GetEntry( aMousePos ) == pEntry && pCurEntry == pEntry ) { - Rectangle aRect(GetPosPixel(), GetSizePixel()); + ::tools::Rectangle aRect(GetPosPixel(), GetSizePixel()); Help::ShowBalloon( this, OutputToScreenPixel(aMousePos), aRect, GetHelpText( pEntry ) ); } } @@ -173,7 +173,7 @@ OUString SvxConfigFunctionListBox::GetHelpText( SvTreeListEntry *pEntry ) void SvxConfigFunctionListBox::FunctionSelected() { - Help::ShowBalloon( this, Point(), Rectangle(), OUString() ); + Help::ShowBalloon( this, Point(), ::tools::Rectangle(), OUString() ); } // drag and drop support diff --git a/cui/source/dialogs/about.cxx b/cui/source/dialogs/about.cxx index 35308f030af9..9384a76743dd 100644 --- a/cui/source/dialogs/about.cxx +++ b/cui/source/dialogs/about.cxx @@ -242,7 +242,7 @@ void AboutDialog::Resize() } } -void AboutDialog::Paint(vcl::RenderContext& rRenderContext, const Rectangle& rRect) +void AboutDialog::Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle& rRect) { rRenderContext.SetClipRegion(vcl::Region(rRect)); diff --git a/cui/source/dialogs/colorpicker.cxx b/cui/source/dialogs/colorpicker.cxx index 54b1e9d7ee4f..548594aa1f9b 100644 --- a/cui/source/dialogs/colorpicker.cxx +++ b/cui/source/dialogs/colorpicker.cxx @@ -153,7 +153,7 @@ class ColorPreviewControl : public Control public: ColorPreviewControl( vcl::Window* pParent, WinBits nStyle ); - virtual void Paint(vcl::RenderContext& rRenderContext, const Rectangle& rRect) override; + virtual void Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle& rRect) override; void SetColor(const Color& rColor); @@ -177,7 +177,7 @@ void ColorPreviewControl::SetColor( const Color& rCol ) } } -void ColorPreviewControl::Paint(vcl::RenderContext& rRenderContext, const Rectangle& rRect) +void ColorPreviewControl::Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle& rRect) { rRenderContext.SetFillColor(maColor); rRenderContext.SetLineColor(maColor); @@ -199,7 +199,7 @@ public: virtual void MouseButtonDown( const MouseEvent& rMEvt ) override; virtual void MouseButtonUp( const MouseEvent& rMEvt ) override; virtual void KeyInput( const KeyEvent& rKEvt ) override; - virtual void Paint(vcl::RenderContext& rRenderContext, const Rectangle& rRect) override; + virtual void Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle& rRect) override; virtual void Resize() override; virtual Size GetOptimalSize() const override; @@ -434,8 +434,8 @@ void ColorFieldControl::ShowPosition( const Point& rPos, bool bUpdate ) Point aPos = maPosition; maPosition.X() = nX - 5; maPosition.Y() = nY - 5; - Invalidate(Rectangle(aPos, Size(11, 11))); - Invalidate(Rectangle(maPosition, Size(11, 11))); + Invalidate(::tools::Rectangle(aPos, Size(11, 11))); + Invalidate(::tools::Rectangle(maPosition, Size(11, 11))); if (bUpdate) { @@ -525,7 +525,7 @@ void ColorFieldControl::KeyInput( const KeyEvent& rKEvt ) Control::KeyInput(rKEvt); } -void ColorFieldControl::Paint(vcl::RenderContext& rRenderContext, const Rectangle& rRect) +void ColorFieldControl::Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle& rRect) { if (!mpBitmap) UpdateBitmap(); @@ -548,7 +548,7 @@ void ColorFieldControl::Paint(vcl::RenderContext& rRenderContext, const Rectangl rRenderContext.SetFillColor(); - rRenderContext.DrawEllipse(Rectangle(maPosition, Size(11, 11))); + rRenderContext.DrawEllipse(::tools::Rectangle(maPosition, Size(11, 11))); } void ColorFieldControl::Resize() @@ -598,7 +598,7 @@ public: virtual void MouseButtonDown( const MouseEvent& rMEvt ) override; virtual void MouseButtonUp( const MouseEvent& rMEvt ) override; virtual void KeyInput( const KeyEvent& rKEvt ) override; - virtual void Paint( vcl::RenderContext& rRenderContext, const Rectangle& rRect ) override; + virtual void Paint( vcl::RenderContext& rRenderContext, const ::tools::Rectangle& rRect ) override; virtual void Resize() override; void UpdateBitmap(); @@ -794,7 +794,7 @@ void ColorSliderControl::KeyInput(const KeyEvent& rKEvt) Control::KeyInput( rKEvt ); } -void ColorSliderControl::Paint(vcl::RenderContext& rRenderContext, const Rectangle& /*rRect*/) +void ColorSliderControl::Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle& /*rRect*/) { if (!mpBitmap) UpdateBitmap(); diff --git a/cui/source/dialogs/cuicharmap.cxx b/cui/source/dialogs/cuicharmap.cxx index 5ac0bf270535..a92f99b6d00c 100644 --- a/cui/source/dialogs/cuicharmap.cxx +++ b/cui/source/dialogs/cuicharmap.cxx @@ -181,7 +181,7 @@ SvxShowText::SvxShowText(vcl::Window* pParent) VCL_BUILDER_FACTORY(SvxShowText) -void SvxShowText::Paint(vcl::RenderContext& rRenderContext, const Rectangle&) +void SvxShowText::Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle&) { rRenderContext.SetFont(maFont); @@ -201,7 +201,7 @@ void SvxShowText::Paint(vcl::RenderContext& rRenderContext, const Rectangle&) bool bShrankFont = false; vcl::Font aOrigFont(rRenderContext.GetFont()); Size aFontSize(aOrigFont.GetFontSize()); - Rectangle aBoundRect; + ::tools::Rectangle aBoundRect; for (long nFontHeight = aFontSize.Height(); nFontHeight > 0; nFontHeight -= 5) { diff --git a/cui/source/dialogs/cuigrfflt.cxx b/cui/source/dialogs/cuigrfflt.cxx index 60ee026c8fd1..7f499c01a776 100644 --- a/cui/source/dialogs/cuigrfflt.cxx +++ b/cui/source/dialogs/cuigrfflt.cxx @@ -46,7 +46,7 @@ Size GraphicPreviewWindow::GetOptimalSize() const } -void GraphicPreviewWindow::Paint(vcl::RenderContext& rRenderContext, const Rectangle& rRect) +void GraphicPreviewWindow::Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle& rRect) { Control::Paint(rRenderContext, rRect); diff --git a/cui/source/dialogs/hangulhanjadlg.cxx b/cui/source/dialogs/hangulhanjadlg.cxx index 9b4eb01f2b61..fb766aba1653 100644 --- a/cui/source/dialogs/hangulhanjadlg.cxx +++ b/cui/source/dialogs/hangulhanjadlg.cxx @@ -101,8 +101,8 @@ namespace svx const OUString& getSecondaryText() const { return m_sSecondaryText; } public: - void Paint( OutputDevice& _rDevice, const Rectangle& _rRect, DrawTextFlags _nTextStyle, - Rectangle* _pPrimaryLocation, Rectangle* _pSecondaryLocation ); + void Paint( OutputDevice& _rDevice, const ::tools::Rectangle& _rRect, DrawTextFlags _nTextStyle, + ::tools::Rectangle* _pPrimaryLocation, ::tools::Rectangle* _pSecondaryLocation ); }; PseudoRubyText::PseudoRubyText() @@ -118,8 +118,8 @@ namespace svx } - void PseudoRubyText::Paint(vcl::RenderContext& rRenderContext, const Rectangle& _rRect, DrawTextFlags _nTextStyle, - Rectangle* _pPrimaryLocation, Rectangle* _pSecondaryLocation ) + void PseudoRubyText::Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle& _rRect, DrawTextFlags _nTextStyle, + ::tools::Rectangle* _pPrimaryLocation, ::tools::Rectangle* _pSecondaryLocation ) { Size aPlaygroundSize(_rRect.GetSize()); @@ -129,8 +129,8 @@ namespace svx aSmallerFont.SetFontHeight( (long)( 0.8 * aSmallerFont.GetFontHeight() ) ); // let's calculate the size of our two texts - Rectangle aPrimaryRect = rRenderContext.GetTextRect( _rRect, m_sPrimaryText, _nTextStyle ); - Rectangle aSecondaryRect; + ::tools::Rectangle aPrimaryRect = rRenderContext.GetTextRect( _rRect, m_sPrimaryText, _nTextStyle ); + ::tools::Rectangle aSecondaryRect; { FontSwitch aFontRestore(rRenderContext, aSmallerFont); aSecondaryRect = rRenderContext.GetTextRect(_rRect, m_sSecondaryText, _nTextStyle); @@ -212,7 +212,7 @@ namespace svx virtual Size GetOptimalSize() const override; protected: - virtual void Paint( vcl::RenderContext& /*rRenderContext*/, const Rectangle& _rRect ) override; + virtual void Paint( vcl::RenderContext& /*rRenderContext*/, const ::tools::Rectangle& _rRect ) override; private: PseudoRubyText m_aRubyText; @@ -229,7 +229,7 @@ namespace svx } - void RubyRadioButton::Paint(vcl::RenderContext& rRenderContext, const Rectangle&) + void RubyRadioButton::Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle&) { HideFocus(); @@ -239,10 +239,10 @@ namespace svx aImageSize.Width() = CalcZoom( aImageSize.Width() ) + 2; // + 2 because otherwise the radiobuttons aImageSize.Height() = CalcZoom( aImageSize.Height() ) + 2; // appear a bit cut from right and top. - Rectangle aOverallRect( Point( 0, 0 ), GetOutputSizePixel() ); + ::tools::Rectangle aOverallRect( Point( 0, 0 ), GetOutputSizePixel() ); aOverallRect.Left() += aImageSize.Width() + 4; // 4 is the separator between the image and the text // inflate the rect a little bit (because the VCL radio button does the same) - Rectangle aTextRect( aOverallRect ); + ::tools::Rectangle aTextRect( aOverallRect ); ++aTextRect.Left(); --aTextRect.Right(); ++aTextRect.Top(); --aTextRect.Bottom(); @@ -269,19 +269,19 @@ namespace svx nTextStyle |= DrawTextFlags::Mnemonic; // paint the ruby text - Rectangle aPrimaryTextLocation; - Rectangle aSecondaryTextLocation; + ::tools::Rectangle aPrimaryTextLocation; + ::tools::Rectangle aSecondaryTextLocation; m_aRubyText.Paint(rRenderContext, aTextRect, nTextStyle, &aPrimaryTextLocation, &aSecondaryTextLocation); // the focus rectangle is to be painted around both texts - Rectangle aCombinedRect(aPrimaryTextLocation); + ::tools::Rectangle aCombinedRect(aPrimaryTextLocation); aCombinedRect.Union(aSecondaryTextLocation); SetFocusRect(aCombinedRect); // let the base class paint the radio button // for this, give it the proper location to paint the image (vertically centered, relative to our text) - Rectangle aImageLocation( Point( 0, 0 ), aImageSize ); + ::tools::Rectangle aImageLocation( Point( 0, 0 ), aImageSize ); sal_Int32 nTextHeight = aSecondaryTextLocation.Bottom() - aPrimaryTextLocation.Top(); aImageLocation.Top() = aPrimaryTextLocation.Top() + ( nTextHeight - aImageSize.Height() ) / 2; aImageLocation.Bottom() = aImageLocation.Top() + aImageSize.Height(); @@ -306,7 +306,7 @@ namespace svx { vcl::Font aSmallerFont( GetFont() ); aSmallerFont.SetFontHeight( static_cast<long>( 0.8 * aSmallerFont.GetFontHeight() ) ); - Rectangle rect( Point(), Size( SAL_MAX_INT32, SAL_MAX_INT32 ) ); + ::tools::Rectangle rect( Point(), Size( SAL_MAX_INT32, SAL_MAX_INT32 ) ); Size aPrimarySize = GetTextRect( rect, m_aRubyText.getPrimaryText() ).GetSize(); Size aSecondarySize; @@ -343,7 +343,7 @@ namespace svx void SuggestionSet::UserDraw( const UserDrawEvent& rUDEvt ) { vcl::RenderContext* pDev = rUDEvt.GetRenderContext(); - Rectangle aRect = rUDEvt.GetRect(); + ::tools::Rectangle aRect = rUDEvt.GetRect(); sal_uInt16 nItemId = rUDEvt.GetItemId(); OUString sText = *static_cast< OUString* >( GetItemData( nItemId ) ); diff --git a/cui/source/dialogs/hlmarkwn.cxx b/cui/source/dialogs/hlmarkwn.cxx index ce7009ec76b2..ad50188d1db1 100644 --- a/cui/source/dialogs/hlmarkwn.cxx +++ b/cui/source/dialogs/hlmarkwn.cxx @@ -92,7 +92,7 @@ Size SvxHlmarkTreeLBox::GetOptimalSize() const return LogicToPixel(Size(103, 162), MapUnit::MapAppFont); } -void SvxHlmarkTreeLBox::Paint(vcl::RenderContext& rRenderContext, const Rectangle& rRect) +void SvxHlmarkTreeLBox::Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle& rRect) { if (!mpParentWnd || mpParentWnd->mnError == LERR_NOERROR) { @@ -102,7 +102,7 @@ void SvxHlmarkTreeLBox::Paint(vcl::RenderContext& rRenderContext, const Rectangl { Erase(rRenderContext); - Rectangle aDrawRect(Point( 0, 0 ), GetSizePixel()); + ::tools::Rectangle aDrawRect(Point( 0, 0 ), GetSizePixel()); OUString aStrMessage; diff --git a/cui/source/dialogs/hltpbase.cxx b/cui/source/dialogs/hltpbase.cxx index 7fefb04ddcb3..6d60d1820df5 100644 --- a/cui/source/dialogs/hltpbase.cxx +++ b/cui/source/dialogs/hltpbase.cxx @@ -200,12 +200,12 @@ void SvxHyperlinkTabPageBase::ShowMarkWnd () static_cast<vcl::Window*>(mpMarkWnd)->Show(); // Size of dialog-window in screen pixels - Rectangle aDlgRect( mpDialog->GetWindowExtentsRelative( nullptr ) ); + ::tools::Rectangle aDlgRect( mpDialog->GetWindowExtentsRelative( nullptr ) ); Point aDlgPos ( aDlgRect.TopLeft() ); Size aDlgSize ( mpDialog->GetSizePixel () ); // Absolute size of the screen - Rectangle aScreen( mpDialog->GetDesktopRectPixel() ); + ::tools::Rectangle aScreen( mpDialog->GetDesktopRectPixel() ); // Size of Extrawindow Size aExtraWndSize( mpMarkWnd->GetSizePixel () ); diff --git a/cui/source/dialogs/thesdlg.cxx b/cui/source/dialogs/thesdlg.cxx index b2cb31592be7..3d44a8593994 100644 --- a/cui/source/dialogs/thesdlg.cxx +++ b/cui/source/dialogs/thesdlg.cxx @@ -255,7 +255,7 @@ void ThesaurusAlternativesCtrl::KeyInput( const KeyEvent& rKEvt ) SvxCheckListBox::KeyInput( rKEvt ); } -void ThesaurusAlternativesCtrl::Paint(vcl::RenderContext& rRenderContext, const Rectangle& rRect) +void ThesaurusAlternativesCtrl::Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle& rRect) { if (!m_pDialog->WordFound()) { diff --git a/cui/source/inc/about.hxx b/cui/source/inc/about.hxx index e3b50e1b5377..9ea511c4488b 100644 --- a/cui/source/inc/about.hxx +++ b/cui/source/inc/about.hxx @@ -66,7 +66,7 @@ private: protected: virtual bool Close() override; - virtual void Paint(vcl::RenderContext& rRenderContext, const Rectangle& rRect) override; + virtual void Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle& rRect) override; virtual void Resize() override; public: diff --git a/cui/source/inc/cuicharmap.hxx b/cui/source/inc/cuicharmap.hxx index 41382bb45949..8d83798ecdbe 100644 --- a/cui/source/inc/cuicharmap.hxx +++ b/cui/source/inc/cuicharmap.hxx @@ -50,7 +50,7 @@ public: virtual Size GetOptimalSize() const override; protected: - virtual void Paint(vcl::RenderContext& rRenderContext, const Rectangle&) override; + virtual void Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle&) override; private: long mnY; diff --git a/cui/source/inc/cuigrfflt.hxx b/cui/source/inc/cuigrfflt.hxx index 1fdeffc57afb..d4b7b085bb92 100644 --- a/cui/source/inc/cuigrfflt.hxx +++ b/cui/source/inc/cuigrfflt.hxx @@ -42,7 +42,7 @@ private: double mfScaleX; double mfScaleY; - virtual void Paint(vcl::RenderContext& rRenderContext, const Rectangle& rRect) override; + virtual void Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle& rRect) override; virtual void Resize() override; virtual Size GetOptimalSize() const override; diff --git a/cui/source/inc/grfpage.hxx b/cui/source/inc/grfpage.hxx index a750bdb26597..2a6fa79a5322 100644 --- a/cui/source/inc/grfpage.hxx +++ b/cui/source/inc/grfpage.hxx @@ -35,7 +35,7 @@ class SvxCropExample : public vcl::Window public: SvxCropExample( vcl::Window* pPar, WinBits nStyle ); - virtual void Paint(vcl::RenderContext& rRenderContext, const Rectangle& rRect) override; + virtual void Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle& rRect) override; virtual void Resize() override; virtual Size GetOptimalSize() const override; diff --git a/cui/source/inc/hlmarkwn.hxx b/cui/source/inc/hlmarkwn.hxx index b652f8c24b1b..5a879197b3ed 100644 --- a/cui/source/inc/hlmarkwn.hxx +++ b/cui/source/inc/hlmarkwn.hxx @@ -51,7 +51,7 @@ public: mpParentWnd = pParent; } - virtual void Paint( vcl::RenderContext& rRenderContext, const Rectangle& rRect ) override; + virtual void Paint( vcl::RenderContext& rRenderContext, const ::tools::Rectangle& rRect ) override; virtual Size GetOptimalSize() const override; }; diff --git a/cui/source/inc/numfmt.hxx b/cui/source/inc/numfmt.hxx index 09a1fc62e5fd..f49f0077e130 100644 --- a/cui/source/inc/numfmt.hxx +++ b/cui/source/inc/numfmt.hxx @@ -48,7 +48,7 @@ private: void InitSettings( bool bForeground, bool bBackground ); protected: - virtual void Paint( vcl::RenderContext& /*rRenderContext*/, const Rectangle& rRect ) override; + virtual void Paint( vcl::RenderContext& /*rRenderContext*/, const ::tools::Rectangle& rRect ) override; virtual void StateChanged( StateChangedType nStateChange ) override; virtual void DataChanged( const DataChangedEvent& rDCEvt ) override; diff --git a/cui/source/inc/numpages.hxx b/cui/source/inc/numpages.hxx index bb30cbd3d751..b09fd9366c9a 100644 --- a/cui/source/inc/numpages.hxx +++ b/cui/source/inc/numpages.hxx @@ -51,7 +51,7 @@ class SvxNumberingPreview : public vcl::Window sal_uInt16 nActLevel; protected: - virtual void Paint( vcl::RenderContext& rRenderContext, const Rectangle& rRect ) override; + virtual void Paint( vcl::RenderContext& rRenderContext, const ::tools::Rectangle& rRect ) override; public: SvxNumberingPreview(vcl::Window* pParent, WinBits nWinBits = WB_BORDER); diff --git a/cui/source/inc/swpossizetabpage.hxx b/cui/source/inc/swpossizetabpage.hxx index aa5f90a7175d..4442250f19cf 100644 --- a/cui/source/inc/swpossizetabpage.hxx +++ b/cui/source/inc/swpossizetabpage.hxx @@ -76,8 +76,8 @@ class SvxSwPosSizeTabPage : public SfxTabPage //'string provider' SvxSwFramePosString m_aFramePosString; - Rectangle m_aRect; //size of all selected objects - Rectangle m_aWorkArea; + ::tools::Rectangle m_aRect; //size of all selected objects + ::tools::Rectangle m_aWorkArea; Point m_aAnchorPos; FrmMap* m_pVMap; diff --git a/cui/source/inc/thesdlg.hxx b/cui/source/inc/thesdlg.hxx index 2a43f980fe52..5e32d0c5630f 100644 --- a/cui/source/inc/thesdlg.hxx +++ b/cui/source/inc/thesdlg.hxx @@ -95,7 +95,7 @@ public: AlternativesExtraData * GetExtraData( const SvTreeListEntry *pEntry ); virtual void KeyInput( const KeyEvent& rKEvt ) override; - virtual void Paint( vcl::RenderContext& rRenderContext, const Rectangle& rRect ) override; + virtual void Paint( vcl::RenderContext& rRenderContext, const ::tools::Rectangle& rRect ) override; }; class ReplaceEdit : public Edit diff --git a/cui/source/options/connpooloptions.cxx b/cui/source/options/connpooloptions.cxx index 514581f9ce8e..642309118778 100644 --- a/cui/source/options/connpooloptions.cxx +++ b/cui/source/options/connpooloptions.cxx @@ -68,7 +68,7 @@ namespace offapp virtual void InitController( ::svt::CellControllerRef& rController, long nRow, sal_uInt16 nCol ) override; virtual ::svt::CellController* GetController( long nRow, sal_uInt16 nCol ) override; - virtual void PaintCell( OutputDevice& rDev, const Rectangle& rRect, sal_uInt16 nColId ) const override; + virtual void PaintCell( OutputDevice& rDev, const ::tools::Rectangle& rRect, sal_uInt16 nColId ) const override; virtual bool SeekRow( long nRow ) override; virtual bool SaveModified() override; @@ -266,7 +266,7 @@ namespace offapp } - void DriverListControl::PaintCell( OutputDevice& rDev, const Rectangle& rRect, sal_uInt16 nColId ) const + void DriverListControl::PaintCell( OutputDevice& rDev, const ::tools::Rectangle& rRect, sal_uInt16 nColId ) const { OSL_ENSURE(m_aSeekRow != m_aSettings.end(), "DriverListControl::PaintCell: invalid row!"); diff --git a/cui/source/options/optchart.cxx b/cui/source/options/optchart.cxx index 34c8f4ed58de..9471cb6f59d5 100644 --- a/cui/source/options/optchart.cxx +++ b/cui/source/options/optchart.cxx @@ -45,7 +45,7 @@ void SvxDefaultColorOptPage::InsertColorEntry(const XColorEntry& rEntry, sal_Int VclPtr<VirtualDevice> xDevice = VclPtr<VirtualDevice>::Create(); xDevice->SetOutputSize(aImageSize); - const Rectangle aRect(Point(0, 0), aImageSize); + const ::tools::Rectangle aRect(Point(0, 0), aImageSize); xDevice->SetFillColor(rColor); xDevice->SetLineColor(rStyleSettings.GetDisableColor()); xDevice->DrawRect(aRect); diff --git a/cui/source/tabpages/backgrnd.cxx b/cui/source/tabpages/backgrnd.cxx index f781f0c7e715..23b9b4cba00b 100644 --- a/cui/source/tabpages/backgrnd.cxx +++ b/cui/source/tabpages/backgrnd.cxx @@ -157,7 +157,7 @@ public: void NotifyChange( const Bitmap* pBitmap ); protected: - virtual void Paint( vcl::RenderContext& /*rRenderContext*/, const Rectangle& rRect ) override; + virtual void Paint( vcl::RenderContext& /*rRenderContext*/, const ::tools::Rectangle& rRect ) override; virtual void DataChanged( const DataChangedEvent& rDCEvt ) override; virtual void Resize() override; @@ -169,7 +169,7 @@ private: Bitmap* pBitmap; Point aDrawPos; Size aDrawSize; - Rectangle aDrawRect; + ::tools::Rectangle aDrawRect; sal_uInt8 nTransparency; }; @@ -282,11 +282,11 @@ void BackgroundPreviewImpl::recalcDrawPos() void BackgroundPreviewImpl::Resize() { Window::Resize(); - aDrawRect = Rectangle(Point(0,0), GetOutputSizePixel()); + aDrawRect = ::tools::Rectangle(Point(0,0), GetOutputSizePixel()); recalcDrawPos(); } -void BackgroundPreviewImpl::Paint(vcl::RenderContext& rRenderContext, const Rectangle&) +void BackgroundPreviewImpl::Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle&) { const StyleSettings& rStyleSettings = rRenderContext.GetSettings().GetStyleSettings(); rRenderContext.SetBackground(Wallpaper(rStyleSettings.GetWindowColor())); diff --git a/cui/source/tabpages/grfpage.cxx b/cui/source/tabpages/grfpage.cxx index 363c56af80c2..cd4bc8a97ba8 100644 --- a/cui/source/tabpages/grfpage.cxx +++ b/cui/source/tabpages/grfpage.cxx @@ -779,16 +779,16 @@ Size SvxCropExample::GetOptimalSize() const VCL_BUILDER_FACTORY_CONSTRUCTOR(SvxCropExample, 0) -void SvxCropExample::Paint(vcl::RenderContext& rRenderContext, const Rectangle&) +void SvxCropExample::Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle&) { Size aWinSize(rRenderContext.PixelToLogic(GetOutputSizePixel())); rRenderContext.SetLineColor(); rRenderContext.SetFillColor(rRenderContext.GetSettings().GetStyleSettings().GetWindowColor()); rRenderContext.SetRasterOp(RasterOp::OverPaint); - rRenderContext.DrawRect(Rectangle(Point(), aWinSize)); + rRenderContext.DrawRect(::tools::Rectangle(Point(), aWinSize)); rRenderContext.SetLineColor(Color(COL_WHITE)); - Rectangle aRect(Point((aWinSize.Width() - aFrameSize.Width())/2, + ::tools::Rectangle aRect(Point((aWinSize.Width() - aFrameSize.Width())/2, (aWinSize.Height() - aFrameSize.Height())/2), aFrameSize); aGrf.Draw(&rRenderContext, aRect.TopLeft(), aRect.GetSize()); diff --git a/cui/source/tabpages/numfmt.cxx b/cui/source/tabpages/numfmt.cxx index 9b3e0e580892..d28fdbff8267 100644 --- a/cui/source/tabpages/numfmt.cxx +++ b/cui/source/tabpages/numfmt.cxx @@ -145,7 +145,7 @@ void SvxNumberPreview::NotifyChange( const OUString& rPrevStr, #* #************************************************************************/ -void SvxNumberPreview::Paint(vcl::RenderContext& rRenderContext, const Rectangle&) +void SvxNumberPreview::Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle&) { vcl::Font aDrawFont = rRenderContext.GetFont(); Size aSzWnd(GetOutputSizePixel()); diff --git a/cui/source/tabpages/numpages.cxx b/cui/source/tabpages/numpages.cxx index 063e265ca04f..3da5e1033da7 100644 --- a/cui/source/tabpages/numpages.cxx +++ b/cui/source/tabpages/numpages.cxx @@ -2349,7 +2349,7 @@ SvxNumberingPreview::SvxNumberingPreview(vcl::Window* pParent, WinBits nWinBits) VCL_BUILDER_FACTORY_ARGS(SvxNumberingPreview, WB_BORDER) // paint preview of numeration -void SvxNumberingPreview::Paint(vcl::RenderContext& rRenderContext, const Rectangle& /*rRect*/) +void SvxNumberingPreview::Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle& /*rRect*/) { Size aSize(rRenderContext.PixelToLogic(GetOutputSizePixel())); @@ -2521,11 +2521,11 @@ void SvxNumberingPreview::Paint(vcl::RenderContext& rRenderContext, const Rectan nXStart = static_cast<sal_uInt16>(rFmt.GetIndentAt() / nWidthRelation); } - Rectangle aRect1(Point(nTextXPos, nYStart + nFontHeight / 2), Size(aSize.Width() / 2, 2)); + ::tools::Rectangle aRect1(Point(nTextXPos, nYStart + nFontHeight / 2), Size(aSize.Width() / 2, 2)); pVDev->SetFillColor(aBackColor); pVDev->DrawRect(aRect1); - Rectangle aRect2(Point(nXStart, nYStart + nLineHeight + nFontHeight / 2 ), Size(aSize.Width() / 2, 2)); + ::tools::Rectangle aRect2(Point(nXStart, nYStart + nLineHeight + nFontHeight / 2 ), Size(aSize.Width() / 2, 2)); pVDev->DrawRect(aRect2); nYStart += 2 * nLineHeight; } @@ -2616,7 +2616,7 @@ void SvxNumberingPreview::Paint(vcl::RenderContext& rRenderContext, const Rectan pVDev->SetFillColor( aLineColor ); pVDev->SetLineColor( aLineColor ); } - Rectangle aRect1(Point(nXStart + nTextOffset, nYStart + nTopOffset), Size(nWidth, nRectHeight)); + ::tools::Rectangle aRect1(Point(nXStart + nTextOffset, nYStart + nTopOffset), Size(nWidth, nRectHeight)); pVDev->DrawRect(aRect1); } } diff --git a/cui/source/tabpages/tabstpge.cxx b/cui/source/tabpages/tabstpge.cxx index f6f42f4312fd..25870806419f 100644 --- a/cui/source/tabpages/tabstpge.cxx +++ b/cui/source/tabpages/tabstpge.cxx @@ -54,7 +54,7 @@ public: virtual ~TabWin_Impl() override { disposeOnce(); } virtual void dispose() override { mpPage.clear(); vcl::Window::dispose(); } - virtual void Paint(vcl::RenderContext& rRenderContext, const Rectangle& rRect) override; + virtual void Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle& rRect) override; void SetTabulatorTabPage(SvxTabulatorTabPage* pPage) { mpPage = pPage; } void SetTabStyle(sal_uInt16 nStyle) {nTabStyle = nStyle; } @@ -79,7 +79,7 @@ void FillUpWithDefTabs_Impl( long nDefDist, SvxTabStopItem& rTabs ) } } -void TabWin_Impl::Paint(vcl::RenderContext& rRenderContext, const Rectangle&) +void TabWin_Impl::Paint(vcl::RenderContext& rRenderContext, const ::tools::Rectangle&) { // Paint tabulators Point aPoint; diff --git a/cui/source/tabpages/transfrm.cxx b/cui/source/tabpages/transfrm.cxx index d8916301c142..e990af8fcd2e 100644 --- a/cui/source/tabpages/transfrm.cxx +++ b/cui/source/tabpages/transfrm.cxx @@ -228,7 +228,7 @@ void SvxAngleTabPage::Construct() } { // #i75273# - Rectangle aTempRect(pView->GetAllMarkedRect()); + ::tools::Rectangle aTempRect(pView->GetAllMarkedRect()); pView->GetSdrPageView()->LogicToPagePos(aTempRect); maRange = basegfx::B2DRange(aTempRect.Left(), aTempRect.Top(), aTempRect.Right(), aTempRect.Bottom()); } @@ -473,7 +473,7 @@ void SvxSlantTabPage::Construct() SetFieldUnit(*m_pMtrRadius, eDlgUnit, true); { // #i75273# - Rectangle aTempRect(pView->GetAllMarkedRect()); + ::tools::Rectangle aTempRect(pView->GetAllMarkedRect()); pView->GetSdrPageView()->LogicToPagePos(aTempRect); maRange = basegfx::B2DRange(aTempRect.Left(), aTempRect.Top(), aTempRect.Right(), aTempRect.Bottom()); } @@ -507,7 +507,7 @@ bool SvxSlantTabPage::FillItemSet(SfxItemSet* rAttrs) if( bModified ) { // set reference points - Rectangle aObjectRect(pView->GetAllMarkedRect()); + ::tools::Rectangle aObjectRect(pView->GetAllMarkedRect()); pView->GetSdrPageView()->LogicToPagePos(aObjectRect); Point aPt = aObjectRect.Center(); @@ -536,7 +536,7 @@ bool SvxSlantTabPage::FillItemSet(SfxItemSet* rAttrs) pModel->BegUndo(pUndo->GetComment()); EnhancedCustomShape2d aShape(pObj); - Rectangle aLogicRect = aShape.GetLogicRect(); + ::tools::Rectangle aLogicRect = aShape.GetLogicRect(); for (int i = 0; i < 2; ++i) { @@ -651,7 +651,7 @@ void SvxSlantTabPage::Reset(const SfxItemSet* rAttrs) Point aMinPosition; aShape.GetHandlePosition(i, aMinPosition); - Rectangle aLogicRect = aShape.GetLogicRect(); + ::tools::Rectangle aLogicRect = aShape.GetLogicRect(); aInitialPosition.Move(-aLogicRect.Left(), -aLogicRect.Top()); aMaxPosition.Move(-aLogicRect.Left(), -aLogicRect.Top()); aMinPosition.Move(-aLogicRect.Left(), -aLogicRect.Top()); @@ -697,7 +697,7 @@ void SvxSlantTabPage::ActivatePage( const SfxItemSet& rSet ) if( SfxItemState::SET == rSet.GetItemState( GetWhich( SID_ATTR_TRANSFORM_INTERN ) , false, reinterpret_cast<SfxPoolItem const **>(&pRectItem) ) ) { - const Rectangle aTempRect(pRectItem->GetValue()); + const ::tools::Rectangle aTempRect(pRectItem->GetValue()); maRange = basegfx::B2DRange(aTempRect.Left(), aTempRect.Top(), aTempRect.Right(), aTempRect.Bottom()); } } @@ -829,13 +829,13 @@ void SvxPositionSizeTabPage::Construct() } { // #i75273# - Rectangle aTempRect(mpView->GetAllMarkedRect()); + ::tools::Rectangle aTempRect(mpView->GetAllMarkedRect()); mpView->GetSdrPageView()->LogicToPagePos(aTempRect); maRange = basegfx::B2DRange(aTempRect.Left(), aTempRect.Top(), aTempRect.Right(), aTempRect.Bottom()); } { // #i75273# - Rectangle aTempRect(mpView->GetWorkArea()); + ::tools::Rectangle aTempRect(mpView->GetWorkArea()); mpView->GetSdrPageView()->LogicToPagePos(aTempRect); maWorkRange = basegfx::B2DRange(aTempRect.Left(), aTempRect.Top(), aTempRect.Right(), aTempRect.Bottom()); } @@ -930,7 +930,7 @@ bool SvxPositionSizeTabPage::FillItemSet( SfxItemSet* rOutAttrs ) double fY((GetCoreValue( *m_pMtrPosY, mePoolUnit ) + maAnchor.getY()) * fUIScale); { // #i75273# - Rectangle aTempRect(mpView->GetAllMarkedRect()); + ::tools::Rectangle aTempRect(mpView->GetAllMarkedRect()); mpView->GetSdrPageView()->LogicToPagePos(aTempRect); maRange = basegfx::B2DRange(aTempRect.Left(), aTempRect.Top(), aTempRect.Right(), aTempRect.Bottom()); } @@ -1149,7 +1149,7 @@ void SvxPositionSizeTabPage::ActivatePage( const SfxItemSet& rSet ) if( SfxItemState::SET == rSet.GetItemState( GetWhich( SID_ATTR_TRANSFORM_INTERN ) , false, reinterpret_cast<SfxPoolItem const **>(&pRectItem) ) ) { { // #i75273# - const Rectangle aTempRect(pRectItem->GetValue()); + const ::tools::Rectangle aTempRect(pRectItem->GetValue()); maRange = basegfx::B2DRange(aTempRect.Left(), aTempRect.Top(), aTempRect.Right(), aTempRect.Bottom()); } @@ -1166,7 +1166,7 @@ DeactivateRC SvxPositionSizeTabPage::DeactivatePage( SfxItemSet* _pSet ) double fY((double)m_pMtrPosY->GetValue()); GetTopLeftPosition(fX, fY, maRange); - const Rectangle aOutRectangle( + const ::tools::Rectangle aOutRectangle( basegfx::fround(fX), basegfx::fround(fY), basegfx::fround(fX + maRange.getWidth()), basegfx::fround(fY + maRange.getHeight())); _pSet->Put(SfxRectangleItem(SID_ATTR_TRANSFORM_INTERN, aOutRectangle)); |