From Xojo Documentation

Revision as of 17:16, 19 November 2020 by GOLone (talk | contribs) (Changed from read-only property to Method)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Graphics.Handle(Type as Graphics.HandleTypes) As Ptr

Supported for all project types and targets.

Gets the OS Handle for the passed Type. Pass the appropriate Graphics.HandleTypes value to specify the Type.


Handle will return nil if the requested handle type is not available or is not supported.

Sample Code

This code gets a handle to the port of the Graphics object on Mac and iOS.

Var h As Ptr = g.Handle(Graphics.HandleTypes.CGContextRef)