(Leadtools.Annotations.Core)

AnnObject Class

Show in webframe





Members 
Defines the base class for all annotation objects.
Object Model
Syntax
public abstract class AnnObject : IAnnObjectCloneable  
Public MustInherit Class AnnObject 
   Implements IAnnObjectCloneable 
public sealed class AnnObject : IAnnObjectCloneable  
@interface LTAnnObject : NSObject<NSCoding,NSCopying>
public abstract class AnnObject implements IAnnObjectCloneable
function Leadtools.Annotations.Core.AnnObject()
Remarks

The AnnObject class provides all the basic functionality common to all LEADTOOLS annotation objects. AnnObject is an abstract class: you cannot instantiate objects of this class directly. Instead, you create an instance of a derived class such as AnnPolylineObject or AnnRectangleObject and use the methods and properties of the base AnnObject through the derived class.

AnnObject contains the following members:

Member Description

Points

Each AnnObject contains an array of Leadtools.LeadPointD points in container coordinates that define its location and size. How these points are interpreted to form the object shape is up to the derived class. For instance, a line object normally has two points: a starting point and an ending point. A rectangle object has four points, one for each corner (to keep track of rotated objects) and so forth.

RotateCenter and RotateGripper

Object rotation center and gripper.

Stroke, Fill and Font

The objects to use when drawing the boundary, filling the interior of an annotation object and drawing any text strings. A line object uses only the stroke object whereas a rectangle object uses both stroke and fill objects. A text object use all three to render its string.

Scale, ScaleVector, Translate and Rotate

Helper method that transforms the object instead of directly manipulating the raw points.

IsVisible and IsSelected

Hides/shows and selects/unselects an object in the container.

Hyperlink, Tag and Metadata

Extra properties that are not used directly by the object, but can be used to store a hyperlink or any user-defined data.

Password, Lock, Unlock, IsLocked and LockPicture

Properties and methods for locking an object with a password. A locked object cannot be moved nor deleted by the automation framework and can be rendered with a special "lock" picture next to it.

Opacity

Opacity value to use when rendering the object.

Labels

Text labels that can be used to draw text legends next to an object, such as a name.

HitTest

Helper method to determine whether a point intersects with this object.

Serialize and Deserialize

Saves and loads objects from an XML element. Used to load and save an object to an annotation file, as well as to perform undo/redo operations.

As well as the members described above, AnnObject contains other properties and methods that are of interest only when creating new object types. For more information, refer to Implementing User-Defined Objects With LEADTOOLS Annotations.

AnnObjects are added to a container using the AnnContainer.Children property. Objects can optionally be added to layers inside the container. For more information, refer to AnnLayer.

Example

For an example, refer to AnnContainer.

Requirements

Target Platforms

See Also

Reference

AnnObject Members
Leadtools.Annotations.Core Namespace
Working with Automated Annotations

 

 


Products | Support | Contact Us | Copyright Notices
© 2006-2014 All Rights Reserved. LEAD Technologies, Inc.