LPrintout is a PowerPlant class that is used for support of printing in your application.
Methods :
The methods in this class are:
Data Members:
The data members in this class are:
Operation:
To learn more about working with LPrintout, refer to The PowerPlant Book.
Source files:
Ancestors:
Purpose:
The constructors create objects from the passed-in parameters.
Access:
Prototype:
LPrintout();
LPrintout( THPrint inPrintRecordH );
LPrintout( LStream *inStream );Parameters:
The parameters for these constructors are:
Purpose:
The destructor destroys the object.
Access:
Prototype:
virtual ~LPrintout();
Purpose:
Set the foreground and background colors of the current port. The Printout or one of its subpanes must already be focused. This is an override of ApplyForeAndBackColors() in LPane.
Purpose:
Count the number of Panels in a Printout. This is an override of CountPanels() in LPane.
Purpose:
Return a new Printout object (and its SubPanes) from the data
in a 'PPob' resource.
Access:
Prototype:
static LPrintout* CreatePrintout(Parameters:
ResIDT inPrintoutID );
The parameter for this method is:
Return:
The pointer to the new object.
Purpose:
Access:
Prototype:
virtual void DoPrintJob();Parameters:
Return:
Purpose:
Make Printout the current port.
Access:
Prototype:
virtual Boolean EstablishPort();Parameters:
Return:
Boolean indicating whether the port was successfully set, false if not.
Purpose:
This is an override of FinishCreateSelf() in LPane.
Purpose:
Return the GrafPort associated with a Printout. This is an override of GetMacPort() in LPane.
Purpose:
Extract information about the print job from the Mac OS Toolbox PrintRecord.
Prototype:
virtual void GetPrintJobSpecs(Parameters:
PanelSpec &outFirstPanel,
PanelSpec &outLastPanel,
UInt16 &outCopyCount );
The parameters for this method are:
Return:
Purpose:
Access:
Prototype:
THPrint GetPrintRecord() const;Parameters:
Return:
Remarks:
Purpose:
Return whether a Printout has the specified attribute.
Access:
Prototype:
Boolean HasAttribute(Parameters:
EPrintAttr inAttribute ) const;
The parameter for this method is:
Return:
Boolean indicating whether the attribute is present (true) or not (false).
Purpose:
Initialize data members to default values.
Access:
Prototype:
void InitPrintout();Parameters:
Return:
Purpose:
Fill in PanelSpec for a given page number.
Access:
Prototype:
virtual void PageToPanel(Parameters:
UInt32 inPageNumber,
PanelSpec &outPanel ) const;
The parameters for this method are:
Return:
Purpose:
Print copies of the specified range of Panels. This is the main "print loop."
Access:
Prototype:
virtual void PrintCopiesOfPages(Parameters:
const PanelSpec &inFirstPanel,
const PanelSpec &inLastPanel,
UInt16 inCopyCount );
The parameters for this method are:
Purpose:
Access:
Prototype:
virtual void PrintPanel(Parameters:
const PanelSpec &inPanel,
RgnHandle inSuperPrintRgnH );
The parameters for this method are:
Purpose:
Access:
Prototype:
virtual void PrintPanelRange(Parameters:
const PanelSpec &inFirstPanel,
const PanelSpec &inLastPanel,
UInt16 inCopyCount );
The parameters for this method are:
Return:
Purpose:
Specify attributes for a Printout.
Access:
Prototype:
void SetAttribute( EPrintAttr inAttribute );Parameters:
The parameter for this method is:
Return:
Purpose:
Sprecify the foreground and/or background colors of a Printout.
Specify nil for inForeColor and/or inBackColor to leave that color trait
unchanged. This is an override of SetForeAndBackColors() in LPane.
Purpose:
Set the Toolbox PrintRecord for a Printout.
Access:
Prototype:
void SetPrintRecord(Parameters:
THPrint inPrintRecordH );
The parameter for this method is:
Return:
Purpose:
Access:
Prototype:
UInt32 mAttributes;
Purpose:
Access:
Prototype:
THPrint mPrintRecordH;
Purpose:
Access:
Prototype:
TPPrPort mPrinterPort;
Purpose:
Access:
Prototype:
WindowPtr mWindowPort;
Purpose:
Access:
Prototype:
UInt32 mHorizPanelCount;
Purpose:
Access:
Prototype:
UInt32 mVertPanelCount;
Purpose:
Access:
Prototype:
RGBColor mForeColor;
Purpose:
Access:
Prototype:
RGBColor mBackColor;