TW3GraphicControl

From Smart Mobile Studio
Jump to: navigation, search


Unit: W3Components.pas


Hierarchy
TObject
TW3TagObj
TW3Component
TW3MovableControl
TW3CustomControl
TW3GraphicControl
Properties
Property-icon.png Canvas
Property-icon.png Context
Property-icon.png DC
Protected Methods
Protected method-icon.png Paint
Methods
Method-icon.png Invalidate
Method-icon.png Refresh
Events
Event-icon.png OnPaint

Properties

Property-icon.png Canvas

Identify TW3Canvas object. Canvas object provide set of functions such as Ellipse that may be used for drawing complex objects.

property Canvas: TW3Canvas read FCanvas;

Remarks:

TW3Canvas provide indirect access to the HTML5 CANVAS element which is created when control is created.


Property-icon.png Context

Provide access to Context object associated with Canvas.

property Context: TW3CustomGraphicContext read FContext;


Property-icon.png DC

Provide access to DC object.

property DC: THandle read GetDC;


Protected Methods

Protected method-icon.png Paint

Called when component is repainted. Descendants may override this method and place drawing code.

procedure Paint; virtual;


Methods

Method-icon.png Invalidate

Insert Paint call into queue.

procedure Invalidate; override;


Method-icon.png Refresh

Immediately call Paint method.

procedure Refresh;

Remarks:

If BeginUpdate method is called, call will be ignored.


Events

Event-icon.png OnPaint

Occurs when Paint method is called.

property OnPaint: TPaintEvent read FOnPaint write FOnPaint;