remove commented-out code in sw/source/core/view
Change-Id: Ib94be6370549c6a71879a5af1eb60808fba762e8
This commit is contained in:
@@ -529,14 +529,12 @@ void SwPagePreviewLayout::_CalcDocPrevwPaintRect()
|
|||||||
|
|
||||||
Size aSize;
|
Size aSize;
|
||||||
if ( mbDoesLayoutColsFitIntoWindow )
|
if ( mbDoesLayoutColsFitIntoWindow )
|
||||||
//aSize.Width() = mnPrevwLayoutWidth;
|
|
||||||
aSize.Width() = std::min( mnPrevwLayoutWidth,
|
aSize.Width() = std::min( mnPrevwLayoutWidth,
|
||||||
maPreviewDocRect.GetWidth() - aTopLeftPos.X() );
|
maPreviewDocRect.GetWidth() - aTopLeftPos.X() );
|
||||||
else
|
else
|
||||||
aSize.Width() = std::min( maPreviewDocRect.GetWidth() - aTopLeftPos.X(),
|
aSize.Width() = std::min( maPreviewDocRect.GetWidth() - aTopLeftPos.X(),
|
||||||
maWinSize.Width() - maAdditionalPaintOffset.X() );
|
maWinSize.Width() - maAdditionalPaintOffset.X() );
|
||||||
if ( mbDoesLayoutRowsFitIntoWindow )
|
if ( mbDoesLayoutRowsFitIntoWindow )
|
||||||
//aSize.Height() = mnPrevwLayoutHeight;
|
|
||||||
aSize.Height() = std::min( mnPrevwLayoutHeight,
|
aSize.Height() = std::min( mnPrevwLayoutHeight,
|
||||||
maPreviewDocRect.GetHeight() - aTopLeftPos.Y() );
|
maPreviewDocRect.GetHeight() - aTopLeftPos.Y() );
|
||||||
else
|
else
|
||||||
|
@@ -456,9 +456,6 @@ bool SwPrintUIOptions::IsPrintTables() const
|
|||||||
// take care of different property names currently in use for this option.
|
// take care of different property names currently in use for this option.
|
||||||
// for compatibility the old name should win (may still be used for PDF export or via Uno API)
|
// for compatibility the old name should win (may still be used for PDF export or via Uno API)
|
||||||
|
|
||||||
// bool bRes = getBoolValue( "PrintTablesGraphicsAndDiagrams", sal_True );
|
|
||||||
// bRes = getBoolValue( "PrintTables", bRes );
|
|
||||||
// return bRes;
|
|
||||||
// for now it was decided that tables should always be printed
|
// for now it was decided that tables should always be printed
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@@ -97,8 +97,6 @@ void ViewShell::PrintProspect(
|
|||||||
|
|
||||||
std::pair< sal_Int32, sal_Int32 > rPagesToPrint =
|
std::pair< sal_Int32, sal_Int32 > rPagesToPrint =
|
||||||
rPrintData.GetRenderData().GetPagePairsForProspectPrinting()[ nRenderer ];
|
rPrintData.GetRenderData().GetPagePairsForProspectPrinting()[ nRenderer ];
|
||||||
// const USHORT nPageMax = static_cast< USHORT >(rPagesToPrint.first > rPagesToPrint.second ?
|
|
||||||
// rPagesToPrint.first : rPagesToPrint.second);
|
|
||||||
OSL_ENSURE( rPagesToPrint.first == -1 || rPrintData.GetRenderData().GetValidPagesSet().count( rPagesToPrint.first ) == 1, "first Page not valid" );
|
OSL_ENSURE( rPagesToPrint.first == -1 || rPrintData.GetRenderData().GetValidPagesSet().count( rPagesToPrint.first ) == 1, "first Page not valid" );
|
||||||
OSL_ENSURE( rPagesToPrint.second == -1 || rPrintData.GetRenderData().GetValidPagesSet().count( rPagesToPrint.second ) == 1, "second Page not valid" );
|
OSL_ENSURE( rPagesToPrint.second == -1 || rPrintData.GetRenderData().GetValidPagesSet().count( rPagesToPrint.second ) == 1, "second Page not valid" );
|
||||||
|
|
||||||
@@ -213,7 +211,6 @@ void ViewShell::PrintProspect(
|
|||||||
|
|
||||||
Point aPos( aSttPt );
|
Point aPos( aSttPt );
|
||||||
aPos -= aShell.maVisArea.Pos();
|
aPos -= aShell.maVisArea.Pos();
|
||||||
// aPos -= aPrtOff;
|
|
||||||
aMapMode.SetOrigin( aPos );
|
aMapMode.SetOrigin( aPos );
|
||||||
pPrinter->SetMapMode( aMapMode );
|
pPrinter->SetMapMode( aMapMode );
|
||||||
pStPage->GetUpper()->Paint( pStPage->Frm() );
|
pStPage->GetUpper()->Paint( pStPage->Frm() );
|
||||||
|
@@ -293,7 +293,6 @@ void ViewShell::CalcPagesForPrint( sal_uInt16 nMax )
|
|||||||
SET_CURR_SHELL( this );
|
SET_CURR_SHELL( this );
|
||||||
|
|
||||||
SwRootFrm* pMyLayout = GetLayout();
|
SwRootFrm* pMyLayout = GetLayout();
|
||||||
// ULONG nStatMax = pLayout->GetPageNum();
|
|
||||||
|
|
||||||
const SwFrm *pPage = pMyLayout->Lower();
|
const SwFrm *pPage = pMyLayout->Lower();
|
||||||
SwLayAction aAction( pMyLayout, Imp() );
|
SwLayAction aAction( pMyLayout, Imp() );
|
||||||
@@ -314,7 +313,6 @@ void ViewShell::CalcPagesForPrint( sal_uInt16 nMax )
|
|||||||
|
|
||||||
maVisArea = aOldVis; //reset due to the paints
|
maVisArea = aOldVis; //reset due to the paints
|
||||||
Imp()->SetFirstVisPageInvalid();
|
Imp()->SetFirstVisPageInvalid();
|
||||||
// SwPaintQueue::Repaint();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
pMyLayout->EndAllAction();
|
pMyLayout->EndAllAction();
|
||||||
@@ -324,10 +322,6 @@ SwDoc * ViewShell::FillPrtDoc( SwDoc *pPrtDoc, const SfxPrinter* pPrt)
|
|||||||
{
|
{
|
||||||
OSL_ENSURE( this->IsA( TYPE(SwFEShell) ),"ViewShell::Prt for FEShell only");
|
OSL_ENSURE( this->IsA( TYPE(SwFEShell) ),"ViewShell::Prt for FEShell only");
|
||||||
SwFEShell* pFESh = (SwFEShell*)this;
|
SwFEShell* pFESh = (SwFEShell*)this;
|
||||||
// Let's create a new document
|
|
||||||
// SwDoc *pPrtDoc = new SwDoc;
|
|
||||||
// pPrtDoc->acquire();
|
|
||||||
// pPrtDoc->SetRefForDocShell( (SvEmbeddedObjectRef*)&(long&)rDocShellRef );
|
|
||||||
pPrtDoc->LockExpFlds();
|
pPrtDoc->LockExpFlds();
|
||||||
|
|
||||||
// use given printer
|
// use given printer
|
||||||
@@ -392,9 +386,6 @@ SwDoc * ViewShell::FillPrtDoc( SwDoc *pPrtDoc, const SfxPrinter* pPrt)
|
|||||||
((SwTxtNode*)pLastNd)->CopyCollFmt( *pTxtNd );
|
((SwTxtNode*)pLastNd)->CopyCollFmt( *pTxtNd );
|
||||||
}
|
}
|
||||||
|
|
||||||
// a new one has been created in CORE (copying OLE objects)
|
|
||||||
// if( aDocShellRef.Is() )
|
|
||||||
// SwDataExchange::InitOle( aDocShellRef, pPrtDoc );
|
|
||||||
// fill it with the selected content
|
// fill it with the selected content
|
||||||
pFESh->Copy( pPrtDoc );
|
pFESh->Copy( pPrtDoc );
|
||||||
|
|
||||||
@@ -511,18 +502,6 @@ sal_Bool ViewShell::PrintOrPDFExport(
|
|||||||
|
|
||||||
::SetSwVisArea( pViewSh2, pStPage->Frm() );
|
::SetSwVisArea( pViewSh2, pStPage->Frm() );
|
||||||
|
|
||||||
// FIXME disabled because rPrintData.aOffset is always (0,0)
|
|
||||||
#if 0
|
|
||||||
// consider offset when printing an envelope
|
|
||||||
if( pStPage->GetFmt()->GetPoolFmtId() == RES_POOLPAGE_JAKET )
|
|
||||||
{
|
|
||||||
Point aNewOrigin = pOutDev->GetMapMode().GetOrigin();
|
|
||||||
aNewOrigin += rPrintData.aOffset;
|
|
||||||
MapMode aTmp( pOutDev->GetMapMode() );
|
|
||||||
aTmp.SetOrigin( aNewOrigin );
|
|
||||||
pOutDev->SetMapMode( aTmp );
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
pShell->InitPrt( pOutDev );
|
pShell->InitPrt( pOutDev );
|
||||||
|
|
||||||
::SetSwVisArea( pViewSh2, pStPage->Frm() );
|
::SetSwVisArea( pViewSh2, pStPage->Frm() );
|
||||||
@@ -572,13 +551,11 @@ void ViewShell::PrtOle2( SwDoc *pDoc, const SwViewOption *pOpt, const SwPrintDat
|
|||||||
// Removing this gives us a performance gain during saving the
|
// Removing this gives us a performance gain during saving the
|
||||||
// document because the thumbnail creation will not trigger a complete
|
// document because the thumbnail creation will not trigger a complete
|
||||||
// formatting of the document.
|
// formatting of the document.
|
||||||
// Format pages for printing
|
|
||||||
// pSh->CalcPagesForPrint( SHRT_MAX );
|
|
||||||
//#39275# now Meyer wants again a Clipping
|
//#39275# now Meyer wants again a Clipping
|
||||||
pOleOut->Push( PUSH_CLIPREGION );
|
pOleOut->Push( PUSH_CLIPREGION );
|
||||||
pOleOut->IntersectClipRegion( aSwRect.SVRect() );
|
pOleOut->IntersectClipRegion( aSwRect.SVRect() );
|
||||||
pSh->GetLayout()->Paint( aSwRect );
|
pSh->GetLayout()->Paint( aSwRect );
|
||||||
// SFX_APP()->SpoilDemoOutput( *pOleOut, rRect );
|
|
||||||
|
|
||||||
pOleOut->Pop();
|
pOleOut->Pop();
|
||||||
// first the CurrShell object needs to be destroyed!
|
// first the CurrShell object needs to be destroyed!
|
||||||
|
Reference in New Issue
Block a user