TCanvas

Abstract base class for a 2D surface that allows drawing upon

Inheritance

LevelAncestorDescription
1TObjectUltimate ancestor in a class hierarchy
2TCanvas

Source

Drawing.Canvas.pas (55)

Description

A canvas uses the painter's algorithm which means that later drawing operations are drawn over earlier operations. For every drawing operation the current Transformation and ClippingWindow are applied. Also, a new layer can be created using PushLayer which will receive all drawing operations until PopLayer is called at which point the layer is composited onto specified area of the canvas. The functions for transformation, clipping and layers come in pairs and should be balanced properly.

Fields

ScopeVisibilityTypeNameDescription
InstanceprotectedTSizedFontFFont
InstanceprotectedTStrokeFStroke
InstanceprotectedTFillFFill

Methods

ScopeVisibilityResultNameDescription
InstanceprotectedSetFont(Value: TSizedFont)
InstanceprotectedSetStroke(Value: TStroke)
InstanceprotectedSetFill(Value: TFill)
InstanceprotectedT2dCompoundAffineTransformationGetTransformation()
InstanceprotectedTClippingWindowGetClippingWindow()
InstanceprotectedFontChanged()
InstanceprotectedStrokeChanged()
InstanceprotectedFillChanged()
InstancepublicDestroy()
InstancepublicFillRectangle(Rectangle: TInteger32Rectangle)
InstancepublicFillRectangle(Rectangle: T2dFloatingPoint64Rectangle)
InstancepublicDrawRectangle(Rectangle: TInteger32Rectangle)
InstancepublicDrawRectangle(Rectangle: T2dFloatingPoint64Rectangle)
InstancepublicDrawRoundedRectangle(Rectangle: T2dFloatingPoint64RoundedRectangle)
InstancepublicFillRoundedRectangle(Rectangle: T2dFloatingPoint64RoundedRectangle)
InstancepublicDrawImage(Position: T2dFloatingPoint64Point; Image: TRasterImage)
InstancepublicStrokeGeometry(Geometry: T2dGeometry)
InstancepublicFillGeometry(Geometry: T2dGeometry)
InstancepublicDrawLine(Point1: TInteger32Point; Point2: TInteger32Point)
InstancepublicDrawLine(Point1: T2dFloatingPoint64Point; Point2: T2dFloatingPoint64Point)
InstancepublicHorizontalLine(HorizontalRange: TInteger32Interval; Y: TInteger32)
InstancepublicVerticalLine(X: TInteger32; VerticalRange: TInteger32Interval)
InstancepublicHorizontalLine(HorizontalRange: TFloatingPoint64Interval; Y: TFloatingPoint64)
InstancepublicVerticalLine(X: TFloatingPoint64; VerticalRange: TFloatingPoint64Interval)
InstancepublicFillEllipse(Ellipse: T2dFloatingPoint64Ellipse)
InstancepublicTextOut(TopLeft: T2dFloatingPoint64Point; Text: TText)
InstancepublicFillText(BaseLineLeft: T2dFloatingPoint64Point; Text: TText)
InstancepublicFillTextLayout(TopLeft: T2dFloatingPoint64Point; Layout: TTextLayout)
InstancepublicOverlayRectangle(Rectangle: TInteger32Rectangle; Factor: TFloatingPoint64)
InstancepublicOverlayGradient(Rectangle: TInteger32Rectangle; Color: TRgbColor; Factors: TFloatingPoint64Interval; Dimension: T2dDimension)
InstancepublicTCanvasPushLayer(Bounds: T2dFloatingPoint64Rectangle; Opacity: TFloatingPoint64)
InstancepublicPopLayer()
InstancepublicTCanvasCreate3dCanvas(Size: TInteger32Size; RotationX: TFloatingPoint64; RotationY: TFloatingPoint64)
InstancepublicDestroy3dCanvas(Canvas: TCanvas)