This function queries a mark for its attributes that are stored in the structure ART_MARK_ATTRIBUTES.
Declaration:
Copy Code | |
---|---|
AT_ERRCOUNT ART_mark_query( HIGEAR hIGear, ART_MARK_INDEX hMarkIndex, LPART_MARK_ATTRIBUTES lpMarkAttr ); |
Arguments:
Name | Type | Description |
hIGear | HIGEAR | HIGEAR handle to the image. |
hMarkIndex | ART_MARK_INDEX | Mark identifier. |
lpMarkAttr | LPART_MARK_ATTRIBUTES | Mark description. |
Return Value:
Returns the number of ImageGear errors that occurred during the function call.
Supported Raster Image Formats:
All pixel formats supported by ImageGear Professional.
Sample:
Annotation
Example:
Copy Code | |
---|---|
HIGEAR hIGear; /* HIGEAR handle of image */ AT_ERRCOUNT nErrcount; /* tally of IG errors on */ /* the stack */ ART_MARK_INDEX hMarkIndex; /* index to the mark */ /* being queried */ ART_MARK_ATTRIBUTES ma ; /* structure holding the */ /* mark's attributes */ UINT arrowCount; /* number of arrow marks */ /* assoc. with image */ /* Get index of first mark created */ ART_mark_first(hIGear, &hMarkIndex, NULL); /* While there are valid index number, iterate through them and keep count of any arrow marks associated with the image */ while (hMarkIndex != ART_INVALID_ID) { nErrcount = ART_mark_query(hIGear, hMarkIndex, &ma); if (ma.dwType = 506) { arrowCount++ } nErrcount = ART_mark_next(hIGear,&HMarkIndex,NULL); } |
Remarks:
The attributes for the mark associated with hMarkIndex are copied into lpMarkAttr, and can then be examined. To bring a particular mark to the front of the stacking order, use ART_mark_bring_to_front().
An error is set if any of the following conditions are met:
- hIGear does not reference a valid ImageGear handle.
- There are no marks with a matching index block.
- The memory pointed to by lpMarkAttr is read-only, invalid or not large enough.