L_LVKRN_API L_INT L_VecSelectObject(pVector, pObject, bSelect)
Selects or unselects an object.
Pointer to a vector handle. Objects within this vector handle will be selected or unselected.
Pointer to a VECTOROBJECT structure that references an object to be selected or unselected.
Flag that indicates whether to select or unselect the specified object. Possible values are:
Value | Meaning |
---|---|
TRUE | Select the specified object. |
FALSE | Unselect the specified object. |
Value | Meaning |
---|---|
SUCCESS | The function was successful. |
< 1 | An error occurred. Refer to Return Codes. |
Selects or unselects an object within the specified vector handle.
Required DLLs and Libraries
This example will select the object under a given 2D point.
L_LTVKRNTEX_API L_INT VecSelectObjectExample(
pVECTORHANDLE pVector,
POINT* pPoint)
{
VECTOROBJECT Object; /* Object under point */
L_INT nRet;
/* Get object under that point */
nRet = L_VecHitTest( pVector, pPoint, &Object );
/* Is there an object under that point? */
if( nRet == SUCCESS )
/* Yes, select it */
nRet = L_VecSelectObject( pVector, &Object, TRUE );
return nRet;
}