The LEADTOOLS C++ Class Library is a wrapper to the LEADTOOLS C API and provides only a subset of the features and functionality otherwise available in the LEADTOOLS C API. For more information about the full feature set of the LEADTOOLS C API, refer to LEADTOOLS C API Introduction.
Is this page helpful?
After initializing and creating the container, the type of object to draw in the container should be set. This is done using the LContainer::SetObjectType function. For example, the sample below sets the container to draw circles:
lcont.SetObjectType (CONTAINER\_OBJECT\_TYPE\_CIRCLE);
This function requires a valid container handle and a constant that specifies the type of object to set.
After setting the object type, the container will begin drawing that object whenever the user clicks and drags the mouse over the window that owns the container. To get the current container object type, call LContainer::GetObjectType.
Each object type drawn by a container can have a different mouse cursor associated with it. For example, when a rectangle object is drawn in the container, one cursor is displayed. If a circle object is drawn in the container a different mouse cursor can be displayed. To set the cursor to use for a specific object type drawn by a container, use LContainer::SetObjectCursor.
To determine the cursor set for a specific object type call LContainer::GetObjectCursor.
LContainer::EditObject displays an object described in a CONTAINEROBJECTDATA structure and makes it available to the user for editing.