LibreOffice Module sw (master)  1
Public Types | Public Member Functions | Public Attributes | Private Attributes | List of all members
SwRenderData Class Reference

A class that stores temporary data that is needed for rendering the document. More...

#include <printdata.hxx>

Collaboration diagram for SwRenderData:
[legend]

Public Types

typedef std::vector< std::pair< sal_Int32, sal_Int32 > > PagePairsVec_t
 

Public Member Functions

 SwRenderData ()
 
 ~SwRenderData ()
 
bool HasPostItData () const
 
void CreatePostItData (SwDoc *pDoc, const SwViewOption *pViewOpt, OutputDevice *pOutDev)
 
void DeletePostItData ()
 
SfxObjectShellLock const & GetTempDocShell () const
 
void SetTempDocShell (SfxObjectShellLock const &)
 
bool IsViewOptionAdjust () const
 
bool NeedNewViewOptionAdjust (const SwViewShell &) const
 
void ViewOptionAdjustStart (SwViewShell &rSh, const SwViewOption &rViewOptions)
 
void ViewOptionAdjust (SwPrintData const *const pPrtOptions, bool setShowPlaceHoldersInPDF)
 
void ViewOptionAdjustStop ()
 
void ViewOptionAdjustCrashPreventionKludge ()
 
bool HasSwPrtOptions () const
 
SwPrintData const * GetSwPrtOptions () const
 
void MakeSwPrtOptions (SwDocShell const *const pDocShell, SwPrintUIOptions const *const pOpt, bool const bIsPDFExport)
 
std::set< sal_Int32 > & GetValidPagesSet ()
 
const std::set< sal_Int32 > & GetValidPagesSet () const
 
std::map< sal_Int32, sal_Int32 > & GetPrinterPaperTrays ()
 a map for printer paper tray numbers to use for each document page a value of -1 for the tray means that there is no specific tray defined More...
 
const std::map< sal_Int32, sal_Int32 > & GetPrinterPaperTrays () const
 
std::vector< sal_Int32 > & GetPagesToPrint ()
 used for 'normal' printing A page value of 0 as entry indicates that this page is not from the document but from the post-it document. More...
 
const std::vector< sal_Int32 > & GetPagesToPrint () const
 
PagePairsVec_tGetPagePairsForProspectPrinting ()
 used for prospect printing only More...
 
const PagePairsVec_tGetPagePairsForProspectPrinting () const
 
const OUString & GetPageRange () const
 
void SetPageRange (const OUString &rRange)
 

Public Attributes

std::unique_ptr< SetGetExpFieldsm_pPostItFields
 an array of "SetGetExpField *" sorted by page and line numbers More...
 
std::unique_ptr< SwViewShellm_pPostItShell
 this contains a SwDoc with the post-it content More...
 

Private Attributes

std::set< sal_Int32 > m_aValidPages
 pages valid for printing (according to the current settings) This set of pages does NOT depend on the 'PageRange' that is used as a printing option! More...
 
std::map< sal_Int32, sal_Int32 > m_aPrinterPaperTrays
 printer paper tray to use for each of the m_aValidPages above More...
 
std::vector< sal_Int32 > m_aPagesToPrint
 vector of pages and their order to be printed (duplicates and any order allowed!) (see 'render' in unotxdoc.cxx) negative entry indicates the page to be printed is from the post-it doc More...
 
std::vector< std::pair< sal_Int32, sal_Int32 > > m_aPagePairs
 for prospect printing: the pairs of pages to be printed together on a single prospect page. More...
 
OUString m_aPageRange
 
SfxObjectShellLock m_xTempDocShell
 temp print document – must live longer than m_pViewOptionAdjust! also this is a Lock and not a Ref because Ref does not delete the doc More...
 
std::unique_ptr< SwViewOptionAdjust_Implm_pViewOptionAdjust
 the view options to be applied for printing More...
 
std::unique_ptr< SwPrintDatam_pPrtOptions
 

Detailed Description

A class that stores temporary data that is needed for rendering the document.

Usually this data is created when 'getRendererCount' is called and and it is used in the 'render' function of that same interface

Definition at line 203 of file printdata.hxx.

Member Typedef Documentation

typedef std::vector< std::pair< sal_Int32, sal_Int32 > > SwRenderData::PagePairsVec_t

Definition at line 263 of file printdata.hxx.

Constructor & Destructor Documentation

SwRenderData::SwRenderData ( )

Definition at line 39 of file printdata.cxx.

SwRenderData::~SwRenderData ( )

Definition at line 43 of file printdata.cxx.

References m_pPostItFields, and m_pPostItShell.

Member Function Documentation

void SwRenderData::CreatePostItData ( SwDoc pDoc,
const SwViewOption pViewOpt,
OutputDevice pOutDev 
)

! Disable spell and grammar checking in the temporary document. ! Otherwise the grammar checker might process it and crash if we later on ! simply delete this document while he is still at it.

Definition at line 49 of file printdata.cxx.

References DeletePostItData(), SwDoc::getIDocumentFieldsAccess(), m_pPostItFields, m_pPostItShell, and sw_GetPostIts().

void SwRenderData::DeletePostItData ( )

Definition at line 64 of file printdata.cxx.

References HasPostItData(), m_pPostItFields, and m_pPostItShell.

Referenced by CreatePostItData().

PagePairsVec_t& SwRenderData::GetPagePairsForProspectPrinting ( )
inline

used for prospect printing only

Definition at line 280 of file printdata.hxx.

References m_aPagePairs.

Referenced by SwDoc::CalculatePagePairsForProspectPrinting(), and SwViewShell::PrintProspect().

const PagePairsVec_t& SwRenderData::GetPagePairsForProspectPrinting ( ) const
inline

Definition at line 281 of file printdata.hxx.

References m_aPagePairs.

const OUString& SwRenderData::GetPageRange ( ) const
inline

Definition at line 283 of file printdata.hxx.

References m_aPageRange.

Referenced by SwDoc::UpdatePagesForPrintingWithPostItData().

std::vector< sal_Int32 >& SwRenderData::GetPagesToPrint ( )
inline

used for 'normal' printing A page value of 0 as entry indicates that this page is not from the document but from the post-it document.

(See also GetPostItStartFrame below)

Definition at line 276 of file printdata.hxx.

References m_aPagesToPrint.

Referenced by SwDoc::CalculatePagesForPrinting(), SwViewShell::PrintOrPDFExport(), and SwDoc::UpdatePagesForPrintingWithPostItData().

const std::vector< sal_Int32 >& SwRenderData::GetPagesToPrint ( ) const
inline

Definition at line 277 of file printdata.hxx.

References m_aPagesToPrint.

std::map< sal_Int32, sal_Int32 >& SwRenderData::GetPrinterPaperTrays ( )
inline

a map for printer paper tray numbers to use for each document page a value of -1 for the tray means that there is no specific tray defined

Definition at line 270 of file printdata.hxx.

References m_aPrinterPaperTrays.

Referenced by SwDoc::CalculatePagePairsForProspectPrinting(), and SwDoc::CalculatePagesForPrinting().

const std::map< sal_Int32, sal_Int32 >& SwRenderData::GetPrinterPaperTrays ( ) const
inline

Definition at line 271 of file printdata.hxx.

References m_aPrinterPaperTrays.

SwPrintData const* SwRenderData::GetSwPrtOptions ( ) const
inline

Definition at line 259 of file printdata.hxx.

SfxObjectShellLock const& SwRenderData::GetTempDocShell ( ) const
inline

Definition at line 248 of file printdata.hxx.

References m_xTempDocShell.

std::set< sal_Int32 >& SwRenderData::GetValidPagesSet ( )
inline
const std::set< sal_Int32 >& SwRenderData::GetValidPagesSet ( ) const
inline

Definition at line 266 of file printdata.hxx.

References m_aValidPages.

bool SwRenderData::HasPostItData ( ) const
inline

Definition at line 244 of file printdata.hxx.

Referenced by DeletePostItData(), and SwDoc::UpdatePagesForPrintingWithPostItData().

bool SwRenderData::HasSwPrtOptions ( ) const
inline

Definition at line 258 of file printdata.hxx.

bool SwRenderData::IsViewOptionAdjust ( ) const
inline

Definition at line 251 of file printdata.hxx.

void SwRenderData::MakeSwPrtOptions ( SwDocShell const *const  pDocShell,
SwPrintUIOptions const *const  pOpt,
bool const  bIsPDFExport 
)
bool SwRenderData::NeedNewViewOptionAdjust ( const SwViewShell rCompare) const

Definition at line 84 of file printdata.cxx.

References m_pViewOptionAdjust.

void SwRenderData::SetPageRange ( const OUString &  rRange)
inline

Definition at line 284 of file printdata.hxx.

Referenced by SwDoc::CalculatePagesForPrinting().

void SwRenderData::SetTempDocShell ( SfxObjectShellLock const &  xShell)

Definition at line 79 of file printdata.cxx.

References m_xTempDocShell.

void SwRenderData::ViewOptionAdjust ( SwPrintData const *const  pPrtOptions,
bool  setShowPlaceHoldersInPDF 
)

Definition at line 100 of file printdata.cxx.

References m_pViewOptionAdjust.

void SwRenderData::ViewOptionAdjustCrashPreventionKludge ( )

Definition at line 110 of file printdata.cxx.

References m_pViewOptionAdjust.

void SwRenderData::ViewOptionAdjustStart ( SwViewShell rSh,
const SwViewOption rViewOptions 
)

Definition at line 89 of file printdata.cxx.

References m_pViewOptionAdjust.

void SwRenderData::ViewOptionAdjustStop ( )

Definition at line 105 of file printdata.cxx.

References m_pViewOptionAdjust.

Member Data Documentation

std::vector< std::pair< sal_Int32, sal_Int32 > > SwRenderData::m_aPagePairs
private

for prospect printing: the pairs of pages to be printed together on a single prospect page.

-1 indicates a half page to be left empty.

Definition at line 219 of file printdata.hxx.

Referenced by GetPagePairsForProspectPrinting().

OUString SwRenderData::m_aPageRange
private

Definition at line 221 of file printdata.hxx.

Referenced by GetPageRange().

std::vector< sal_Int32 > SwRenderData::m_aPagesToPrint
private

vector of pages and their order to be printed (duplicates and any order allowed!) (see 'render' in unotxdoc.cxx) negative entry indicates the page to be printed is from the post-it doc

Definition at line 215 of file printdata.hxx.

Referenced by GetPagesToPrint().

std::map< sal_Int32, sal_Int32 > SwRenderData::m_aPrinterPaperTrays
private

printer paper tray to use for each of the m_aValidPages above

Definition at line 210 of file printdata.hxx.

Referenced by GetPrinterPaperTrays().

std::set< sal_Int32 > SwRenderData::m_aValidPages
private

pages valid for printing (according to the current settings) This set of pages does NOT depend on the 'PageRange' that is used as a printing option!

the set of possible pages (see StringRangeEnumerator::getRangesFromString )

Definition at line 207 of file printdata.hxx.

Referenced by GetValidPagesSet().

std::unique_ptr<SetGetExpFields> SwRenderData::m_pPostItFields

an array of "SetGetExpField *" sorted by page and line numbers

Definition at line 236 of file printdata.hxx.

Referenced by CreatePostItData(), DeletePostItData(), SwDoc::UpdatePagesForPrintingWithPostItData(), and ~SwRenderData().

std::unique_ptr<SwViewShell> SwRenderData::m_pPostItShell

this contains a SwDoc with the post-it content

Definition at line 238 of file printdata.hxx.

Referenced by CreatePostItData(), DeletePostItData(), SwViewShell::PrintOrPDFExport(), SwDoc::UpdatePagesForPrintingWithPostItData(), and ~SwRenderData().

std::unique_ptr<SwPrintData> SwRenderData::m_pPrtOptions
private

Definition at line 230 of file printdata.hxx.

Referenced by MakeSwPrtOptions().

std::unique_ptr<SwViewOptionAdjust_Impl> SwRenderData::m_pViewOptionAdjust
private

the view options to be applied for printing

Definition at line 228 of file printdata.hxx.

Referenced by NeedNewViewOptionAdjust(), ViewOptionAdjust(), ViewOptionAdjustCrashPreventionKludge(), ViewOptionAdjustStart(), and ViewOptionAdjustStop().

SfxObjectShellLock SwRenderData::m_xTempDocShell
private

temp print document – must live longer than m_pViewOptionAdjust! also this is a Lock and not a Ref because Ref does not delete the doc

Definition at line 225 of file printdata.hxx.

Referenced by GetTempDocShell(), and SetTempDocShell().


The documentation for this class was generated from the following files: