AnnSetMetafile method (ILEADRasterAnnotation)
short AnnSetMetafile(long hObject, long hMetafile, short nType, VARIANT_BOOL bSelected); | |
Overview |
Refer to Implementing Annotations. |
Remarks
(Document/Medical only) Sets the metafile associated with Stamp objects (including the Rubber Stamp tools), Encrypt object, Hotspot objects, or Freehand Hotspot objects.
The AnnSetMetafile method is valid only for the following object types:
The Stamp object (which include the Rubber Stamp tools) can display text, a bitmap or a metafile. Only one of these three can be displayed at any time—setting the object to one of these destroys any settings for the other two.
Initially, the Stamp object displays text. The difference between the Stamp and the Rubber Stamp is that initially whereas the Stamp does not display an image, the Rubber Stamp tools are set to display different metafiles (one for each rubber stamp selection).
Initially, the Hotspot, Freehand Hotspot, and Encrypt objects are also set to display predefined metafiles.
Call the AnnGetMetafile method to retrieve a metafile for an object. Call the AnnSetMetafile method to change the metafile for an object. Any new objects will still get the default metafile.
If nType == ANN_METAFILE_USER, then hMetafile is the metafile handle. You can use the windows functionality to create a metafile.
If nType is one of the ANN_METAFILE_XXX values, then hMetafile is ignored and the default metafiles are used instead. The annotation DLL has 28 predefined metafiles. You can change the predefined metafiles by using the AnnSetPredefinedMetafile method.
If the value of the AnnContainer property is passed as the hObject parameter, the method will modify all the annotations in the container depending on the value of bSelected parameter.
If the value of the AnnAutomation property is passed as the hObject parameter, the method will modify the default values used whenever an annotation is created.
See Also