GLG Toolkit, C / C++ API Library  Version 4.5
Attaching Custom Data

This group contains functions for associating arbitrary application data with graphical objects. More...

Detailed Description

This group contains functions for associating arbitrary application data with graphical objects.

This is different from Custom Data that can be attached to objects in the GLG Graphics Builder: Custom Data are stored only as GLG D, S or G data objects, while these functions may be used to attach data of an arbitrary type, such as a pointer to a structure.

The attached data are persistent only at run time and are not saved with the object when the drawing is saved.

Functions

void * GlgGetObjectData (GlgObject object)
 Retrieves application data attached to the object via GlgSetObjectData. More...
 
void GlgSetObjectData (GlgObject object, void *data)
 Attaches arbitrary application data to a graphical object. More...
 

Function Documentation

◆ GlgGetObjectData()

void* GlgGetObjectData ( GlgObject  object)

Retrieves application data attached to the object via GlgSetObjectData.

Parameters
objectAn object to retrieve the data from.
Returns
The data attached to the object.

◆ GlgSetObjectData()

void GlgSetObjectData ( GlgObject  object,
void *  data 
)

Attaches arbitrary application data to a graphical object.

Parameters
objectAn object the data will be attached to.
dataThe data that will be attached.