vcl: make Region ctors explicit to prevent overloading desasters
Change-Id: Id36d125b4940418833bec31a4710d6cd545629e0
This commit is contained in:
parent
913f175b32
commit
38d3e115c1
@ -88,7 +88,7 @@ namespace vclcanvas
|
||||
// wouldn't save much render time, and b) will clutter
|
||||
// scrolled sprite content outside this area)
|
||||
rOutDev.EnableMapMode( sal_False );
|
||||
rOutDev.SetClipRegion( rRequestedArea );
|
||||
rOutDev.SetClipRegion(Region(rRequestedArea));
|
||||
|
||||
// repaint affected sprite directly to output device (at
|
||||
// the actual screen output position)
|
||||
|
@ -1007,7 +1007,7 @@ void DataBrowser::PaintCell(
|
||||
// clipping
|
||||
if( aPos.X() < rRect.Right() || aPos.X() + TxtSize.Width() > rRect.Right() ||
|
||||
aPos.Y() < rRect.Top() || aPos.Y() + TxtSize.Height() > rRect.Bottom())
|
||||
rDev.SetClipRegion( rRect );
|
||||
rDev.SetClipRegion(Region(rRect));
|
||||
|
||||
// allow for a disabled control ...
|
||||
sal_Bool bEnabled = IsEnabled();
|
||||
|
@ -429,7 +429,7 @@ void AboutDialog::MoveControl(Control& rControl, sal_Int32 X, sal_Int32 Y)
|
||||
|
||||
void AboutDialog::Paint( const Rectangle& rRect )
|
||||
{
|
||||
SetClipRegion( rRect );
|
||||
SetClipRegion(Region(rRect));
|
||||
Point aPos ( rRect.GetWidth() - aBackgroundBitmap.GetSizePixel().Width(), rRect.GetHeight() - aBackgroundBitmap.GetSizePixel().Height() );
|
||||
DrawBitmapEx( aPos, aBackgroundBitmap );
|
||||
}
|
||||
|
@ -294,7 +294,7 @@ namespace offapp
|
||||
|
||||
if (m_aSeekRow != m_aSettings.end())
|
||||
{
|
||||
rDev.SetClipRegion(rRect);
|
||||
rDev.SetClipRegion(Region(rRect));
|
||||
|
||||
sal_uInt16 nStyle = TEXT_DRAW_CLIP;
|
||||
if (!IsEnabled())
|
||||
|
@ -370,7 +370,9 @@ namespace dbaui
|
||||
|
||||
if( aPos.X() < rRect.Right() || aPos.X() + aTextSize.Width() > rRect.Right() ||
|
||||
aPos.Y() < rRect.Top() || aPos.Y() + aTextSize.Height() > rRect.Bottom() )
|
||||
rDev.SetClipRegion( rRect );
|
||||
{
|
||||
rDev.SetClipRegion(Region(rRect));
|
||||
}
|
||||
|
||||
rDev.DrawText( aPos, aText );
|
||||
|
||||
|
@ -435,7 +435,9 @@ void OTableGrantControl::PaintCell( OutputDevice& rDev, const Rectangle& rRect,
|
||||
|
||||
if( aPos.X() < rRect.Right() || aPos.X() + nWidth > rRect.Right() ||
|
||||
aPos.Y() < rRect.Top() || aPos.Y() + nHeight > rRect.Bottom() )
|
||||
rDev.SetClipRegion( rRect );
|
||||
{
|
||||
rDev.SetClipRegion(Region(rRect));
|
||||
}
|
||||
|
||||
rDev.DrawText( aPos, aText );
|
||||
}
|
||||
|
@ -155,7 +155,7 @@ DBG_NAME(IndexFieldsControl)
|
||||
// clipping
|
||||
if (aPos.X() < _rRect.Right() || aPos.X() + TxtSize.Width() > _rRect.Right() ||
|
||||
aPos.Y() < _rRect.Top() || aPos.Y() + TxtSize.Height() > _rRect.Bottom())
|
||||
_rDev.SetClipRegion( _rRect );
|
||||
_rDev.SetClipRegion(Region(_rRect));
|
||||
|
||||
// allow for a disabled control ...
|
||||
sal_Bool bEnabled = IsEnabled();
|
||||
|
@ -1245,7 +1245,7 @@ sal_Bool OSelectionBrowseBox::SeekRow(long nRow)
|
||||
void OSelectionBrowseBox::PaintCell(OutputDevice& rDev, const Rectangle& rRect, sal_uInt16 nColumnId) const
|
||||
{
|
||||
DBG_CHKTHIS(OSelectionBrowseBox,NULL);
|
||||
rDev.SetClipRegion( rRect );
|
||||
rDev.SetClipRegion(Region(rRect));
|
||||
|
||||
OTableFieldDescRef pEntry = NULL;
|
||||
sal_uInt16 nPos = GetColumnPos(nColumnId);
|
||||
|
@ -376,7 +376,7 @@ void OTableEditorCtrl::PaintCell(OutputDevice& rDev, const Rectangle& rRect,
|
||||
const String aText( GetCellText( m_nCurrentPos, nColumnId ));
|
||||
|
||||
rDev.Push( PUSH_CLIPREGION );
|
||||
rDev.SetClipRegion( rRect );
|
||||
rDev.SetClipRegion(Region(rRect));
|
||||
rDev.DrawText( rRect, aText, TEXT_DRAW_LEFT | TEXT_DRAW_VCENTER );
|
||||
rDev.Pop();
|
||||
}
|
||||
|
@ -387,7 +387,7 @@ void GridWindow::drawNew()
|
||||
{
|
||||
if( m_nValues && m_pXValues && m_pNewYValues )
|
||||
{
|
||||
SetClipRegion( m_aGridArea );
|
||||
SetClipRegion(Region(m_aGridArea));
|
||||
SetLineColor( Color( COL_YELLOW ) );
|
||||
for( int i = 0; i < m_nValues-1; i++ )
|
||||
{
|
||||
|
@ -573,7 +573,7 @@ void OFieldExpressionControl::PaintCell( OutputDevice& rDev, const Rectangle& rR
|
||||
|
||||
if( aPos.X() < rRect.Right() || aPos.X() + aTextSize.Width() > rRect.Right() ||
|
||||
aPos.Y() < rRect.Top() || aPos.Y() + aTextSize.Height() > rRect.Bottom() )
|
||||
rDev.SetClipRegion( rRect );
|
||||
rDev.SetClipRegion(Region(rRect));
|
||||
|
||||
rDev.DrawText( aPos, aText );
|
||||
|
||||
|
@ -4573,7 +4573,7 @@ void ScGridWindow::UpdateFormulas()
|
||||
PolyPolygon aChangedPoly( aOutputData.GetChangedArea() ); // logic (PixelToLogic)
|
||||
if ( aChangedPoly.Count() )
|
||||
{
|
||||
Invalidate( aChangedPoly );
|
||||
Invalidate(Region(aChangedPoly));
|
||||
}
|
||||
|
||||
CheckNeedsRepaint(); // #i90362# used to be called via Draw() - still needed here
|
||||
|
@ -156,8 +156,8 @@ static void lcl_DrawOneFrame( OutputDevice* pDev, const Rectangle& rInnerPixel,
|
||||
}
|
||||
long nClipStartX = bLayoutRTL ? aOuter.Left() + nBWidth : aInner.Left();
|
||||
long nClipEndX = bLayoutRTL ? aInner.Right() : aOuter.Right() - nBWidth;
|
||||
pDev->SetClipRegion( Rectangle( nClipStartX, nButtonY + nVer/2,
|
||||
nClipEndX, nButtonY + nVer/2 + aTextSize.Height() ) );
|
||||
pDev->SetClipRegion( Region(Rectangle( nClipStartX, nButtonY + nVer/2,
|
||||
nClipEndX, nButtonY + nVer/2 + aTextSize.Height())) );
|
||||
}
|
||||
|
||||
pDev->DrawText( Point( nTextStart, nButtonY + nVer/2 ), rTitle );
|
||||
@ -1252,7 +1252,7 @@ void ScGridWindow::DrawButtons( SCCOL nX1, SCCOL nX2, ScTableInfo& rTabInfo, Out
|
||||
Rectangle aRect = GetListValButtonRect( aListValPos );
|
||||
aComboButton.SetPosPixel( aRect.TopLeft() );
|
||||
aComboButton.SetSizePixel( aRect.GetSize() );
|
||||
pContentDev->SetClipRegion( aRect );
|
||||
pContentDev->SetClipRegion(Region(aRect));
|
||||
aComboButton.Draw( false, false );
|
||||
pContentDev->SetClipRegion(); // always called from Draw() without clip region
|
||||
aComboButton.SetPosPixel( aOldPos ); // restore old state
|
||||
|
@ -512,9 +512,9 @@ void ScOutlineWindow::DataChanged( const DataChangedEvent& rDCEvt )
|
||||
|
||||
void ScOutlineWindow::SetEntryAreaClipRegion()
|
||||
{
|
||||
SetClipRegion( Rectangle(
|
||||
SetClipRegion( Region(Rectangle(
|
||||
GetPoint( 0, mnMainFirstPos ),
|
||||
GetPoint( GetOutputSizeLevel() - 1, mnMainLastPos ) ) );
|
||||
GetPoint( GetOutputSizeLevel() - 1, mnMainLastPos ))));
|
||||
}
|
||||
|
||||
void ScOutlineWindow::DrawLineRel(
|
||||
|
@ -1596,7 +1596,8 @@ void ScPrintFunc::PrintArea( SCCOL nX1, SCROW nY1, SCCOL nX2, SCROW nY2,
|
||||
if( aTableParam.bCellContent )
|
||||
aOutputData.DrawBackground();
|
||||
|
||||
pDev->SetClipRegion( Rectangle( aPos, Size( aOutputData.GetScrW(), aOutputData.GetScrH() ) ) );
|
||||
pDev->SetClipRegion(Region(Rectangle(
|
||||
aPos, Size(aOutputData.GetScrW(), aOutputData.GetScrH()))));
|
||||
pDev->SetClipRegion();
|
||||
|
||||
if( aTableParam.bCellContent )
|
||||
@ -1773,7 +1774,7 @@ void ScPrintFunc::PrintHF( long nPageNo, sal_Bool bHeader, long nStartY,
|
||||
|
||||
// Clipping fuer Text
|
||||
|
||||
pDev->SetClipRegion( Rectangle( aStart, aPaperSize ) );
|
||||
pDev->SetClipRegion(Region(Rectangle(aStart, aPaperSize)));
|
||||
|
||||
// links
|
||||
|
||||
|
@ -264,7 +264,7 @@ Bitmap DrawDocShell::GetPagePreviewBitmap(SdPage* pPage, sal_uInt16 nMaxEdgePixe
|
||||
pView->SetActiveLayer( pFrameView->GetActiveLayer() );
|
||||
}
|
||||
|
||||
pView->CompleteRedraw( &aVDev, Rectangle( aNullPt, aSize ) );
|
||||
pView->CompleteRedraw( &aVDev, Region(Rectangle(aNullPt, aSize)) );
|
||||
|
||||
// IsRedrawReady() always gives sal_True while ( !pView->IsRedrawReady() ) {}
|
||||
delete pView;
|
||||
|
@ -327,7 +327,8 @@ namespace {
|
||||
if (pView!=NULL && bPrintMarkedOnly)
|
||||
pView->DrawMarkedObj(rPrinter);
|
||||
else
|
||||
rPrintView.CompleteRedraw(&rPrinter, Rectangle(Point(0,0), rPage.GetSize()));
|
||||
rPrintView.CompleteRedraw(&rPrinter,
|
||||
Region(Rectangle(Point(0,0), rPage.GetSize())));
|
||||
|
||||
rPrinter.SetMapMode(aOriginalMapMode);
|
||||
|
||||
|
@ -64,7 +64,7 @@ void ClientView::InvalidateOneWin(::Window& rWin)
|
||||
|
||||
void ClientView::InvalidateOneWin(::Window& rWin, const Rectangle& rRect)
|
||||
{
|
||||
CompleteRedraw(&rWin, rRect);
|
||||
CompleteRedraw(&rWin, Region(rRect));
|
||||
}
|
||||
|
||||
void ClientView::CompleteRedraw(OutputDevice* pOutDev, const Region& rReg, sdr::contact::ViewObjectContactRedirector* pRedirector )
|
||||
|
@ -363,7 +363,7 @@ namespace svt
|
||||
Point aPos( rRect.TopLeft() );
|
||||
|
||||
if ( ( aImageSize.Width() > rRect.GetWidth() ) || ( aImageSize.Height() > rRect.GetHeight() ) )
|
||||
rDev.SetClipRegion(rRect);
|
||||
rDev.SetClipRegion(Region(rRect));
|
||||
|
||||
if ( aImageSize.Width() < rRect.GetWidth() )
|
||||
aPos.X() += ( rRect.GetWidth() - aImageSize.Width() ) / 2;
|
||||
|
@ -690,7 +690,7 @@ void SvxIconChoiceCtrl_Impl::Paint( const Rectangle& rRect )
|
||||
sal_Bool bResetClipRegion = sal_False;
|
||||
if( !pView->IsClipRegion() )
|
||||
{
|
||||
Rectangle aOutputArea( GetOutputRect() );
|
||||
Region const aOutputArea( GetOutputRect() );
|
||||
bResetClipRegion = sal_True;
|
||||
pView->SetClipRegion( aOutputArea );
|
||||
}
|
||||
@ -740,7 +740,7 @@ void SvxIconChoiceCtrl_Impl::RepaintEntries( sal_uInt16 nEntryFlagsMask )
|
||||
if( !pView->IsClipRegion() )
|
||||
{
|
||||
bResetClipRegion = sal_True;
|
||||
pView->SetClipRegion( aOutRect );
|
||||
pView->SetClipRegion(Region(aOutRect));
|
||||
}
|
||||
for( size_t nCur = 0; nCur < nCount; nCur++ )
|
||||
{
|
||||
@ -1832,7 +1832,7 @@ void SvxIconChoiceCtrl_Impl::PaintEntry( SvxIconChoiceCtrlEntry* pEntry, const P
|
||||
Rectangle aOutputArea( GetOutputRect() );
|
||||
if( aOutputArea.IsOver(aTextRect) || aOutputArea.IsOver(aBmpRect) )
|
||||
{
|
||||
pView->SetClipRegion( aOutputArea );
|
||||
pView->SetClipRegion(Region(aOutputArea));
|
||||
bResetClipRegion = sal_True;
|
||||
}
|
||||
}
|
||||
@ -2764,7 +2764,7 @@ void SvxIconChoiceCtrl_Impl::SelectRect( const Rectangle& rRect, bool bAdd,
|
||||
if( !pView->IsClipRegion() )
|
||||
{
|
||||
bResetClipRegion = sal_True;
|
||||
pView->SetClipRegion( GetOutputRect() );
|
||||
pView->SetClipRegion(Region(GetOutputRect()));
|
||||
}
|
||||
|
||||
for( size_t nPos = 0; nPos < nCount; nPos++ )
|
||||
|
@ -554,7 +554,7 @@ bool GraphicObject::Draw( OutputDevice* pOut, const Point& rPt, const Size& rSz,
|
||||
}
|
||||
else
|
||||
{
|
||||
pOut->IntersectClipRegion( aClipPolyPoly );
|
||||
pOut->IntersectClipRegion(Region(aClipPolyPoly));
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -693,7 +693,7 @@ sal_Bool GraphicObject::StartAnimation( OutputDevice* pOut, const Point& rPt, co
|
||||
if( bRectClip )
|
||||
pOut->IntersectClipRegion( aClipPolyPoly.GetBoundRect() );
|
||||
else
|
||||
pOut->IntersectClipRegion( aClipPolyPoly );
|
||||
pOut->IntersectClipRegion(Region(aClipPolyPoly));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -471,7 +471,10 @@ namespace svt
|
||||
:m_rDevice( i_rImpl.m_rTabBar )
|
||||
{
|
||||
m_rDevice.Push( PUSH_CLIPREGION );
|
||||
m_rDevice.SetClipRegion( i_rImpl.m_aNormalizer.getTransformed( i_rImpl.m_aGeometry.getItemsRect(), i_rImpl.m_eTabAlignment ) );
|
||||
m_rDevice.SetClipRegion(Region(
|
||||
i_rImpl.m_aNormalizer.getTransformed(
|
||||
i_rImpl.m_aGeometry.getItemsRect(),
|
||||
i_rImpl.m_eTabAlignment )));
|
||||
}
|
||||
|
||||
~ClipItemRegion()
|
||||
@ -1042,7 +1045,7 @@ namespace svt
|
||||
// background
|
||||
const Rectangle aNormalizedPaintArea( m_pImpl->m_aNormalizer.getNormalized( i_rRect, m_pImpl->m_eTabAlignment ) );
|
||||
m_pImpl->m_aRenderDevice.Push( PUSH_CLIPREGION );
|
||||
m_pImpl->m_aRenderDevice.SetClipRegion( aNormalizedPaintArea );
|
||||
m_pImpl->m_aRenderDevice.SetClipRegion(Region(aNormalizedPaintArea));
|
||||
m_pImpl->m_pRenderer->renderBackground();
|
||||
m_pImpl->m_aRenderDevice.Pop();
|
||||
m_pImpl->CopyFromRenderDevice( aNormalizedPaintArea );
|
||||
|
@ -715,7 +715,7 @@ inline Polygon lclCreatePolygon( const PointVec& rPoints )
|
||||
}
|
||||
|
||||
/** Returns a polygon constructed from the five passed points. */
|
||||
Polygon lclCreatePolygon( const Point& rP1, const Point& rP2, const Point& rP3, const Point& rP4, const Point& rP5 )
|
||||
Region lclCreatePolygon( const Point& rP1, const Point& rP2, const Point& rP3, const Point& rP4, const Point& rP5 )
|
||||
{
|
||||
PointVec aPoints;
|
||||
aPoints.reserve( 5 );
|
||||
@ -724,7 +724,7 @@ Polygon lclCreatePolygon( const Point& rP1, const Point& rP2, const Point& rP3,
|
||||
aPoints.push_back( rP3 );
|
||||
aPoints.push_back( rP4 );
|
||||
aPoints.push_back( rP5 );
|
||||
return lclCreatePolygon( aPoints );
|
||||
return Region(lclCreatePolygon(aPoints));
|
||||
}
|
||||
|
||||
/** Sets the color of the passed frame style to the output device.
|
||||
|
@ -568,7 +568,9 @@ sal_Bool SgaObjectSvDraw::DrawCentered( OutputDevice* pOut, const FmFormModel& r
|
||||
pOut->Push();
|
||||
pOut->SetMapMode( aMap );
|
||||
aView.ShowSdrPage( const_cast< FmFormPage* >( pPage ));
|
||||
aView.CompleteRedraw( pOut, Rectangle( pOut->PixelToLogic( Point() ), pOut->GetOutputSize() ) );
|
||||
aView.CompleteRedraw( pOut,
|
||||
Region(Rectangle(pOut->PixelToLogic(Point()),
|
||||
pOut->GetOutputSize())));
|
||||
pOut->Pop();
|
||||
|
||||
bRet = sal_True;
|
||||
|
@ -363,7 +363,7 @@ void _SdrItemBrowserControl::PaintField(OutputDevice& rDev, const Rectangle& rRe
|
||||
rDev.DrawText(rRect.TopLeft(),pEntry->aName);
|
||||
}
|
||||
} else {
|
||||
rDev.SetClipRegion(aR);
|
||||
rDev.SetClipRegion(Region(aR));
|
||||
rDev.DrawText(aR.TopLeft(),GetCellText(nAktPaintRow,nColumnId));
|
||||
rDev.SetClipRegion();
|
||||
}
|
||||
|
@ -279,7 +279,7 @@ void SwNoTxtFrm::Paint(SwRect const& rRect, SwPrintData const*const) const
|
||||
FindFlyFrm()->GetContour( aPoly, sal_True )
|
||||
)
|
||||
{
|
||||
pOut->SetClipRegion( aPoly );
|
||||
pOut->SetClipRegion(Region(aPoly));
|
||||
bClip = false;
|
||||
}
|
||||
|
||||
|
@ -2370,7 +2370,7 @@ void SwTabFrmPainter::PaintLines( OutputDevice& rDev, const SwRect& rRect ) cons
|
||||
Size aSize( rRect.SSize() );
|
||||
// Hack! Necessary, because the layout is not pixel aligned!
|
||||
aSize.Width() += nPixelSzW; aSize.Height() += nPixelSzH;
|
||||
rDev.SetClipRegion( Rectangle( rRect.Pos(), aSize ) );
|
||||
rDev.SetClipRegion(Region(Rectangle(rRect.Pos(), aSize)));
|
||||
|
||||
// The following stuff if necessary to have the new table borders fit
|
||||
// into a ::SwAlignRect adjusted world.
|
||||
@ -4010,7 +4010,7 @@ void SwFlyFrm::Paint(SwRect const& rRect, SwPrintData const*const) const
|
||||
ViewShell *pSh = getRootFrm()->GetCurrShell();
|
||||
if ( !pOut->GetConnectMetaFile() || !pSh || !pSh->GetWin() )
|
||||
{
|
||||
pOut->SetClipRegion( aPoly );
|
||||
pOut->SetClipRegion(Region(aPoly));
|
||||
}
|
||||
for ( sal_uInt16 i = 0; i < aRegion.size(); ++i )
|
||||
PaintBackground( aRegion[i], pPage, rAttrs, sal_False, sal_True );
|
||||
|
@ -158,7 +158,7 @@ void SwLabPreview::Paint(const Rectangle &)
|
||||
DrawLine(Point(lX0, lY0 + lOutlineH - 1), Point(lX0 + lOutlineW - 1, lY0 + lOutlineH - 1)); // Down
|
||||
|
||||
// Labels
|
||||
SetClipRegion (Rectangle(Point(lX0, lY0), Size(lOutlineW, lOutlineH)));
|
||||
SetClipRegion(Region(Rectangle(Point(lX0, lY0), Size(lOutlineW, lOutlineH))));
|
||||
SetFillColor( COL_LIGHTGRAYBLUE );
|
||||
for (sal_uInt16 nRow = 0; nRow < Min((sal_uInt16) 2, (sal_uInt16) aItem.nRows); nRow++)
|
||||
for (sal_uInt16 nCol = 0; nCol < Min((sal_uInt16) 2, (sal_uInt16) aItem.nCols); nCol++)
|
||||
|
@ -79,12 +79,12 @@ public: // public within vcl
|
||||
#endif
|
||||
|
||||
public:
|
||||
Region();
|
||||
Region( RegionType eType );
|
||||
Region( const Rectangle& rRect );
|
||||
Region( const Polygon& rPolygon );
|
||||
Region( const PolyPolygon& rPolyPoly );
|
||||
Region( const basegfx::B2DPolyPolygon& );
|
||||
explicit Region();
|
||||
explicit Region( RegionType eType );
|
||||
explicit Region( const Rectangle& rRect );
|
||||
explicit Region( const Polygon& rPolygon );
|
||||
explicit Region( const PolyPolygon& rPolyPoly );
|
||||
explicit Region( const basegfx::B2DPolyPolygon& );
|
||||
Region( const Region& rRegion );
|
||||
~Region();
|
||||
|
||||
|
@ -505,13 +505,13 @@ long SpinButton::PreNotify( NotifyEvent& rNEvt )
|
||||
Region aRgn( GetActiveClipRegion() );
|
||||
if( pLastRect )
|
||||
{
|
||||
SetClipRegion( *pLastRect );
|
||||
SetClipRegion(Region(*pLastRect));
|
||||
Paint( *pLastRect );
|
||||
SetClipRegion( aRgn );
|
||||
}
|
||||
if( pRect )
|
||||
{
|
||||
SetClipRegion( *pRect );
|
||||
SetClipRegion(Region(*pRect));
|
||||
Paint( *pRect );
|
||||
SetClipRegion( aRgn );
|
||||
}
|
||||
|
@ -117,7 +117,7 @@ sal_Bool ImplDrawNativeSpinfield( Window *pWin, const SpinbuttonValue& rSpinbutt
|
||||
bNativeOK = pBorder->DrawNativeControl( CTRL_SPINBOX, PART_ENTIRE_CONTROL, aRgn, CTRL_STATE_ENABLED,
|
||||
rSpinbuttonValue, rtl::OUString() );
|
||||
|
||||
pBorder->SetClipRegion( oldRgn );
|
||||
pBorder->SetClipRegion(Region(oldRgn));
|
||||
}
|
||||
}
|
||||
return bNativeOK;
|
||||
@ -925,13 +925,13 @@ long SpinField::PreNotify( NotifyEvent& rNEvt )
|
||||
Region aRgn( GetActiveClipRegion() );
|
||||
if( pLastRect )
|
||||
{
|
||||
SetClipRegion( *pLastRect );
|
||||
SetClipRegion(Region(*pLastRect));
|
||||
Paint( *pLastRect );
|
||||
SetClipRegion( aRgn );
|
||||
}
|
||||
if( pRect )
|
||||
{
|
||||
SetClipRegion( *pRect );
|
||||
SetClipRegion(Region(*pRect));
|
||||
Paint( *pRect );
|
||||
SetClipRegion( aRgn );
|
||||
}
|
||||
|
@ -585,14 +585,14 @@ void DrawSlideCirc(sal_Int16 cx, sal_Int16 cy, sal_Int16 rx, sal_Int16 ry, ObjAr
|
||||
b=Int1+sal_Int16((sal_Int32)(Int2-Int1)*(sal_Int32)(i-y1) /(sal_Int32)(y2-y1+1));
|
||||
if (b!=b0) {
|
||||
SgfAreaColorIntens(F.FMuster,(sal_uInt8)Col1,(sal_uInt8)Col2,(sal_uInt8)b0,rOut);
|
||||
rOut.SetClipRegion(Rectangle(x1,i0,x2,i-1));
|
||||
rOut.SetClipRegion(Region(Rectangle(x1,i0,x2,i-1)));
|
||||
rOut.DrawEllipse(Rectangle(x1,y1,x2,y2));
|
||||
i0=i; b0=b;
|
||||
}
|
||||
i++;
|
||||
}
|
||||
SgfAreaColorIntens(F.FMuster,(sal_uInt8)Col1,(sal_uInt8)Col2,(sal_uInt8)Int2,rOut);
|
||||
rOut.SetClipRegion(Rectangle(x1,i0,x2,y2));
|
||||
rOut.SetClipRegion(Region(Rectangle(x1,i0,x2,y2)));
|
||||
rOut.DrawEllipse(Rectangle(x1,y1,x2,y2));
|
||||
rOut.SetClipRegion(ClipMerk);
|
||||
} break;
|
||||
@ -604,14 +604,14 @@ void DrawSlideCirc(sal_Int16 cx, sal_Int16 cy, sal_Int16 rx, sal_Int16 ry, ObjAr
|
||||
b=Int1+sal_Int16((sal_Int32)(Int2-Int1)*(sal_Int32)(i-x1) /(sal_Int32)(x2-x1+1));
|
||||
if (b!=b0) {
|
||||
SgfAreaColorIntens(F.FMuster,(sal_uInt8)Col1,(sal_uInt8)Col2,(sal_uInt8)b0,rOut);
|
||||
rOut.SetClipRegion(Rectangle(i0,y1,i-1,y2));
|
||||
rOut.SetClipRegion(Region(Rectangle(i0,y1,i-1,y2)));
|
||||
rOut.DrawEllipse(Rectangle(x1,y1,x2,y2));
|
||||
i0=i; b0=b;
|
||||
}
|
||||
i++;
|
||||
}
|
||||
SgfAreaColorIntens(F.FMuster,(sal_uInt8)Col1,(sal_uInt8)Col2,(sal_uInt8)Int2,rOut);
|
||||
rOut.SetClipRegion(Rectangle(i0,y1,x2,y2));
|
||||
rOut.SetClipRegion(Region(Rectangle(i0,y1,x2,y2)));
|
||||
rOut.DrawEllipse(Rectangle(x1,y1,x2,y2));
|
||||
rOut.SetClipRegion(ClipMerk);
|
||||
} break;
|
||||
|
@ -1403,7 +1403,9 @@ void GDIMetaFile::Rotate( long nAngle10 )
|
||||
case( META_ISECTRECTCLIPREGION_ACTION ):
|
||||
{
|
||||
MetaISectRectClipRegionAction* pAct = (MetaISectRectClipRegionAction*) pAction;
|
||||
aMtf.AddAction( new MetaISectRegionClipRegionAction( ImplGetRotatedPolygon( pAct->GetRect(), aRotAnchor, aRotOffset, fSin, fCos ) ) );
|
||||
aMtf.AddAction( new MetaISectRegionClipRegionAction(Region(
|
||||
ImplGetRotatedPolygon( pAct->GetRect(), aRotAnchor,
|
||||
aRotOffset, fSin, fCos )) ) );
|
||||
}
|
||||
break;
|
||||
|
||||
|
@ -800,7 +800,7 @@ void OutputDevice::DrawGradient( const PolyPolygon& rPolyPoly,
|
||||
if( OUTDEV_PRINTER == meOutDevType )
|
||||
{
|
||||
Push( PUSH_CLIPREGION );
|
||||
IntersectClipRegion( rPolyPoly );
|
||||
IntersectClipRegion(Region(rPolyPoly));
|
||||
DrawGradient( aRect, rGradient );
|
||||
Pop();
|
||||
}
|
||||
|
@ -348,7 +348,7 @@ void OutputDevice::DrawTransparent( const PolyPolygon& rPolyPoly,
|
||||
}
|
||||
|
||||
Push( PUSH_CLIPREGION | PUSH_LINECOLOR );
|
||||
IntersectClipRegion( rPolyPoly );
|
||||
IntersectClipRegion(Region(rPolyPoly));
|
||||
SetLineColor( GetFillColor() );
|
||||
const sal_Bool bOldMap = mbMap;
|
||||
EnableMapMode( sal_False );
|
||||
|
@ -295,7 +295,7 @@ sal_Bool OutputDevice::DrawNativeControl( ControlType nType,
|
||||
|
||||
Region aTestRegion( GetActiveClipRegion() );
|
||||
aTestRegion.Intersect( rControlRegion );
|
||||
if( aTestRegion == rControlRegion )
|
||||
if (aTestRegion == Region(rControlRegion))
|
||||
nState |= CTRL_CACHING_ALLOWED; // control is not clipped, caching allowed
|
||||
|
||||
sal_Bool bRet = mpGraphics->DrawNativeControl(nType, nPart, screenRegion, nState, *aScreenCtrlValue, aCaption, this );
|
||||
|
@ -2322,7 +2322,7 @@ sal_Bool Region::IsInside( const Rectangle& rRect ) const
|
||||
return sal_False;
|
||||
|
||||
// create region from rectangle and intersect own region
|
||||
Region aRegion = rRect;
|
||||
Region aRegion(rRect);
|
||||
aRegion.Exclude( *this );
|
||||
|
||||
// rectangle is inside if exclusion is empty
|
||||
@ -2341,7 +2341,7 @@ sal_Bool Region::IsOver( const Rectangle& rRect ) const
|
||||
// Can we optimize this ??? - is used in StarDraw for brushes pointers
|
||||
// Why we have no IsOver for Regions ???
|
||||
// create region from rectangle and intersect own region
|
||||
Region aRegion = rRect;
|
||||
Region aRegion(rRect);
|
||||
aRegion.Intersect( *this );
|
||||
|
||||
// rectangle is over if include is not empty
|
||||
|
@ -4038,7 +4038,7 @@ Region MenuFloatingWindow::ImplCalcClipRegion( sal_Bool bIncludeLogo ) const
|
||||
if ( pMenu && pMenu->pLogo && !bIncludeLogo )
|
||||
aRect.Left() += pMenu->pLogo->aBitmap.GetSizePixel().Width();
|
||||
|
||||
Region aRegion = aRect;
|
||||
Region aRegion(aRect);
|
||||
if ( pMenu && pMenu->pLogo && bIncludeLogo && nScrollerHeight )
|
||||
aRegion.Union( Rectangle( Point(), Size( pMenu->pLogo->aBitmap.GetSizePixel().Width(), aOutSz.Height() ) ) );
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user