Skip to main content
Pie
ra0

TcxCanvas.PathToRegion(Boolean) Method

Converts the selected GDI path into a region.

Declaration

function PathToRegion(AConsiderOrigin: Boolean = True): TcxRegion;

Parameters

Name Type
AConsiderOrigin Boolean

Returns

Type
TcxRegion

Remarks

A GDI path is a complex, irregular shape formed by multiple draw calls enclosed between the BeginPath and EndPath procedure calls. A PathToRegion procedure call converts the selected path into a new region and discards the path from the device context of the underlying canvas. The region’s position automatically shifts according to the device context origin. You can pass False as the optional ConsiderOrigin parameter to avoid this behavior.

Note

A PathToRegion procedure call has no effect if the device context of the canvas has no selected GDI path.

See Also