Kaydet (Commit) 3e5caf40 authored tarafından Miklos Vajna's avatar Miklos Vajna Kaydeden (comit) Andras Timar

SwFlyFrm::Paint: use vcl::RenderContext

Change-Id: Id6bd21deda59a6eecfff39907d967b78b881a1e6
(cherry picked from commit 74768909)
üst 1b7560af
......@@ -4134,9 +4134,8 @@ void SwFlyFrm::Paint(vcl::RenderContext& rRenderContext, SwRect const& rRect, Sw
SwRect aRect( rRect );
aRect._Intersection( Frm() );
OutputDevice* pOut = gProp.pSGlobalShell->GetOut();
pOut->Push( PushFlags::CLIPREGION );
pOut->SetClipRegion();
rRenderContext.Push( PushFlags::CLIPREGION );
rRenderContext.SetClipRegion();
const SwPageFrm* pPage = FindPageFrm();
const SwNoTextFrm *pNoText = Lower() && Lower()->IsNoTextFrm()
......@@ -4239,8 +4238,8 @@ void SwFlyFrm::Paint(vcl::RenderContext& rRenderContext, SwRect const& rRect, Sw
//one.
// OD 2004-04-23 #116347#
pOut->Push( PushFlags::FILLCOLOR|PushFlags::LINECOLOR );
pOut->SetLineColor();
rRenderContext.Push( PushFlags::FILLCOLOR|PushFlags::LINECOLOR );
rRenderContext.SetLineColor();
pPage = FindPageFrm();
......@@ -4263,20 +4262,20 @@ void SwFlyFrm::Paint(vcl::RenderContext& rRenderContext, SwRect const& rRect, Sw
}
if ( bContour )
{
pOut->Push();
rRenderContext.Push();
// #i80822#
// apply clip region under the same conditions, which are
// used in <SwNoTextFrm::Paint(..)> to set the clip region
// for painting the graphic/OLE. Thus, the clip region is
// also applied for the PDF export.
SwViewShell *pSh = getRootFrm()->GetCurrShell();
if ( !pOut->GetConnectMetaFile() || !pSh || !pSh->GetWin() )
if ( !rRenderContext.GetConnectMetaFile() || !pSh || !pSh->GetWin() )
{
pOut->SetClipRegion(vcl::Region(aPoly));
rRenderContext.SetClipRegion(vcl::Region(aPoly));
}
for ( size_t i = 0; i < aRegion.size(); ++i )
PaintBackground( aRegion[i], pPage, rAttrs, false, true );
pOut->Pop();
rRenderContext.Pop();
}
else
for ( size_t i = 0; i < aRegion.size(); ++i )
......@@ -4290,7 +4289,7 @@ void SwFlyFrm::Paint(vcl::RenderContext& rRenderContext, SwRect const& rRect, Sw
PaintBorder( aTmp, pPage, rAttrs );
}
pOut->Pop();
rRenderContext.Pop();
}
}
......@@ -4330,8 +4329,8 @@ void SwFlyFrm::Paint(vcl::RenderContext& rRenderContext, SwRect const& rRect, Sw
// Add subsidiary lines of fly frame and its lowers
RefreshLaySubsidiary( pPage, aRect );
// paint subsidiary lines of fly frame and its lowers
gProp.pSSpecSubsLines->PaintSubsidiary( pOut, NULL, gProp );
gProp.pSSubsLines->PaintSubsidiary( pOut, gProp.pSLines, gProp );
gProp.pSSpecSubsLines->PaintSubsidiary( &rRenderContext, NULL, gProp );
gProp.pSSubsLines->PaintSubsidiary( &rRenderContext, gProp.pSLines, gProp );
if ( !bSubsLineRectsCreated )
// unlock subsidiary lines
gProp.pSSubsLines->LockLines( false );
......@@ -4355,12 +4354,12 @@ void SwFlyFrm::Paint(vcl::RenderContext& rRenderContext, SwRect const& rRect, Sw
// OD 19.12.2002 #106318# - first paint lines added by fly frame paint
// and then unlock other lines.
gProp.pSLines->PaintLines( pOut, gProp );
gProp.pSLines->PaintLines( &rRenderContext, gProp );
gProp.pSLines->LockLines( false );
// have to paint frame borders added in heaven layer here...
ProcessPrimitives(gProp.pBLines->GetBorderLines_Clear());
pOut->Pop();
rRenderContext.Pop();
if ( gProp.pSProgress && pNoText )
gProp.pSProgress->Reschedule();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment