[Overview][Types][Classes][Variables][Index] | Reference for unit 'Printers' (#lcl)

# TPrinterCanvas

[Properties (by Name)] [Methods (by Name)] [Events (by Name)]

TPrinterCanvas - instance of TCanvas specially designed for printers

## Declaration

Source position: printers.pas line 57

`type TPrinterCanvas = class(TCanvas)`
`protected`
`procedure BeginDoc; virtual;` |  | BeginDoc - method to start printing a document
`procedure NewPage; virtual;` |  | NewPage - method to start printing a new page
`procedure EndDoc; virtual;` |  | EndDoc - method to finish printing a document
`function GetLeftMargin;` |  | GetLeftMargin - returns the size of teh left margin
`function GetTopMargin;` |  | GetTopMargin - returns the size of the top margin
`function GetBottomMargin;` |  | GetBottomMargin - returns the size of the bottom margin
`function GetRightMargin;` |  | GetRightMargin - returns the size of the right margin
`public`
`constructor Create(); virtual;` |  | Create - constructor to make a canvas for the specified printer type, APrinter
`procedure Changing; override;` |  | Changing - method for dealing with changes in printing staus
`property Printer: TPrinter; [r]` |  | The type of Printer for which this canvas is preparing the document
`property Title: String; [rw]` |  | The Title of the current printer canvas
`property PageHeight: Integer; [r]` |  | The PageHeight to be used for the current canvas
`property PageWidth: Integer; [r]` |  | The PageWidth to be used for the current canvas
`property PaperWidth: Integer; [rw]`
`property PaperHeight: Integer; [rw]`
`property PageNumber: Integer; [r]` |  | PageNumber - the number of the current page being prepared for printing
`property TopMargin: Integer; [rw]` |  | The size of the TopMargin
`property LeftMargin: Integer; [rw]` |  | The size of the LeftMargin
`property BottomMargin: Integer; [rw]` |  | The size of the BottomMargin
`property RightMargin: Integer; [rw]` |  | the size of the RightMargin
`property Orientation: TPrinterOrientation; [rw]`
`property XDPI: Integer; [rw]`
`property YDPI: Integer; [rw]`
`end;`

## Inheritance

`TPrinterCanvas` |  | TPrinterCanvas - instance of TCanvas specially designed for printers
`TCanvas` |  | TCanvas - where most of the drawing is performed
`TFPCustomCanvas`
?
`TObject`

The latest version of this document can be found at lazarus-ccr.sourceforge.net .