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

# TPrinter.CanvasClass

Class reference used to create new instances of the printer canvas.

## Declaration

Source position: printers.pas line 333

`public property TPrinter.CanvasClass : TPrinterCanvasRef read GetCanvasClass write SetCanvasClass;`

## Description

CanvasClass is a TPrinterCanvasRef property which contains the class reference used to create new instances of the class for the Canvas property. In TPrinter, the TPrinterCanvas class is used for the Canvas property. In a descendent class, a different printer canvas may be needed. CanvasClass allows the descendant to determine the correct class type in its DoGetDefaultCanvasClass method. The property value is always returns Nil when RawMode is set to True.

CanvasClass is used in the read access specifier for the Canvas property to create a new instance of the class reference and assign it to the Canvas member (when needed).

## See also

TPrinterCanvasRef |  | Reference to the TPrinterCanvas class.
TPrinter.Canvas |  | The Canvas to be used for laying out the current document ready for printing.
TPrinter.RawMode |  | Indicates if raw output is used for the device (as opposed to a page description language).
TPrinter.DoGetDefaultCanvasClass |  | Performs actions to get the default class used for the Canvas property.