TArrow.Paint procedure
Implements the paint handler used to draw the control.
Declaration
procedure Paint; overrideDescription
Paint is an overridden method in
TArrow. It extends the
inherited to method to perform actions needed to draw the shape and an
optional shadow.
Paint calculates the internal TPoint instances needed for the triangular shape using the values in ArrowType and ArrowPointerAngle. It configures the control Canvas with the values in Color, ArrowColor, ShadowColor, and AntiAliasingMode.
Methods in Canvas are called to render the shape. FillRect is called to draw the background for the control Polygon is called to draw both the shadow and the arrow on the control. The MoveTo and LineTo methods are used to draw the lines needed for an unfilled shadow.
Use Color to set the background color for the client area in the shape.
Use ArrowColor to set the color for the Pen and Brush used to draw the arrow shape.
Use ShadowType and ShadowColor to draw a shadow for the shape with the desired color and drawing style.
Paint calls the inherited method prior to exit to signal the OnPaint event handler (when assigned).
Paint is called when the WM_PAINT window message is handled for the control.
See also
An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.
