PrintCalcData Struct Reference

Calculated factors for the current PDF printing (either horizontal or vertical). More...

List of all members.

Public Member Functions

 PrintCalcData ()
bool WriteToRegistry (const PrintPageData &orig, LPCTSTR lpPrefix)
 Write the calculated data to the registry.
bool ReadFromRegistry (const PrintPageData &orig, LPCTSTR lpPrefix)
 Read the calculated data from the registry.
void FromData (const PrintPageData &orig, int nEnd, int nStart, double dEnd, double dStart, long lFull)
 Calculates the factors.
long FixLocation (double dPos, double dFullPage)
 Calculates the PDF location from the Excel location according to the factors.

Public Attributes

double dFactor
 The factor to multiple Excel's (wrong) location values with.
long lOffset
 The offset to start with.
long lFullSize
 Full size of the page.
bool bCenter
 true if printing is centered, false if not
bool bForceDPI
 true to use the default DPI setting (300) instead of the original DPI

Detailed Description

Calculated factors for the current PDF printing (either horizontal or vertical).

Definition at line 691 of file CCPDFExcelAddinObj.cpp.


Constructor & Destructor Documentation

PrintCalcData::PrintCalcData (  )  [inline]

Default constructor

Definition at line 696 of file CCPDFExcelAddinObj.cpp.


Member Function Documentation

long PrintCalcData::FixLocation ( double  dPos,
double  dFullPage 
)

Calculates the PDF location from the Excel location according to the factors.

Parameters:
dPos The Excel's (alleged) print position
dFullPage Excel's full page size (for centering)
Returns:
The actual print location

Definition at line 803 of file CCPDFExcelAddinObj.cpp.

References bCenter, dFactor, and lOffset.

Referenced by CCCPDFExcelAddinObj::DoPrint().

void PrintCalcData::FromData ( const PrintPageData orig,
int  nEnd,
int  nStart,
double  dEnd,
double  dStart,
long  lFull 
)

Calculates the factors.

Parameters:
orig The matching page setup data
nEnd Actual print end location
nStart Actual print start location
dEnd Excel's print end location
dStart Excel's print start location
lFull The full width of the page in the print

Definition at line 787 of file CCPDFExcelAddinObj.cpp.

References PrintPageData::bCenter, bCenter, dFactor, lFullSize, and lOffset.

bool PrintCalcData::ReadFromRegistry ( const PrintPageData orig,
LPCTSTR  lpPrefix 
)

Read the calculated data from the registry.

Parameters:
orig The matching page setup data
lpPrefix Prefix to use for registry key
Returns:
true if read successfully, false if failed

Definition at line 724 of file CCPDFExcelAddinObj.cpp.

References PrintPageData::bCenter, bCenter, bForceDPI, PrintPageData::CreateName(), dFactor, CCRegistry::GetBinary(), CCRegistry::GetNumber(), lFullSize, lOffset, REGISTRY_DATA_PATH, and tstring.

bool PrintCalcData::WriteToRegistry ( const PrintPageData orig,
LPCTSTR  lpPrefix 
)

Write the calculated data to the registry.

Parameters:
orig The matching page setup data
lpPrefix Prefix to use for registry key
Returns:
true if saved successfully, false if failed

Definition at line 760 of file CCPDFExcelAddinObj.cpp.

References bForceDPI, PrintPageData::CreateName(), dFactor, lFullSize, lOffset, REGISTRY_DATA_PATH, CCRegistry::SetBinary(), CCRegistry::SetNumber(), and tstring.


The documentation for this struct was generated from the following file:

Generated on Mon Jun 18 12:52:51 2012 for Excel to PDF Converter by doxygen 1.6.1