Leadtools.Annotations Requires Document/Medical product license | Send comments on this topic. | Back to Introduction - All Topics | Help Version 15.10.31
AnnProtractorObject Class
See Also  Members   Example 
Leadtools.Annotations Namespace : AnnProtractorObject Class




Defines an annotation protractor object.

Object Model



















Syntax

Visual Basic (Declaration) 
<SerializableAttribute()>
Public Class AnnProtractorObject 
   Inherits AnnObject
   Implements IAnnProtractorObjectIAnnRulerObject 
Visual Basic (Usage)Copy Code
Dim instance As AnnProtractorObject
C# 
[SerializableAttribute()]
public class AnnProtractorObject : AnnObject, IAnnProtractorObjectIAnnRulerObject  
Managed Extensions for C++ 
[SerializableAttribute()]
public __gc class AnnProtractorObject : public AnnObject, IAnnProtractorObjectIAnnRulerObject  
C++/CLI 
[SerializableAttribute()]
public ref class AnnProtractorObject : public AnnObject, IAnnProtractorObjectIAnnRulerObject  

Example

This example creates a new protractor object.

Visual BasicCopy Code
Private Sub AnnProtractorObject_AnnProtractorObject(ByVal container As AnnContainer)
   Dim protractor As AnnProtractorObject = New AnnProtractorObject()
   protractor.Pen = New AnnPen(Color.Green, New AnnLength(3))
   protractor.CenterPoint = New AnnPoint(10.0F, 4.5F, AnnUnit.Inch)
   protractor.FirstPoint = New AnnPoint(5.0F, 20.0F, AnnUnit.Inch)
   protractor.SecondPoint = New AnnPoint(20.56F, 40.3F, AnnUnit.Inch)
   protractor.MeasurementUnit = AnnUnit.SmartEnglish
   protractor.TickMarksLength = New AnnLength(0.5F, AnnUnit.Inch)
   protractor.ShowTickMarks = True
   protractor.GaugeLength = New AnnLength(1.0F, AnnUnit.Inch)
   protractor.ShowGauge = True
   protractor.ShowLength = True
   protractor.Precision = 2
   protractor.AngularUnit = AnnAngularUnit.Degree
   protractor.Acute = True
   protractor.AnglePrecision = 2
   protractor.ArcRadius = New AnnLength(0.5F, AnnUnit.Inch)
   container.Objects.Add(protractor)
End Sub
C#Copy Code
private void AnnProtractorObject_AnnProtractorObject(AnnContainer container) 

   AnnProtractorObject protractor = new AnnProtractorObject(); 
   protractor.Pen = new AnnPen(Color.Green, new AnnLength(3)); 
   protractor.CenterPoint = new AnnPoint(10.0F, 4.5F, AnnUnit.Inch); 
   protractor.FirstPoint = new AnnPoint(5.0F, 20.0F, AnnUnit.Inch); 
   protractor.SecondPoint = new AnnPoint(20.56F, 40.3F, AnnUnit.Inch); 
   protractor.MeasurementUnit = AnnUnit.SmartEnglish; 
   protractor.TickMarksLength = new AnnLength(0.5F, AnnUnit.Inch); 
   protractor.ShowTickMarks = true; 
   protractor.GaugeLength = new AnnLength(1.0F, AnnUnit.Inch); 
   protractor.ShowGauge = true; 
   protractor.ShowLength = true; 
   protractor.Precision = 2; 
   protractor.AngularUnit = AnnAngularUnit.Degree; 
   protractor.Acute = true; 
   protractor.AnglePrecision = 2; 
   protractor.ArcRadius = new AnnLength(0.5F, AnnUnit.Inch); 
   container.Objects.Add(protractor); 
}

Remarks

The protractor annotation object consists of two rulers joined at a point to create an angle. The center point is CenterPoint, the first line ends at FirstPoint and the second point ends at SecondPoint.
For more information, refer to Using Protractors in Annotation Objects.

For more information about the protractor annotation object refer to AnnProtractorObject. For more information about the automated protractor clip annotation object, refer to Annotation Objects - Automated Features and Automated Annotations - Protractor Tab.

Inheritance Hierarchy

System.Object
   Leadtools.Annotations.AnnDrawable
      Leadtools.Annotations.AnnObject
         Leadtools.Annotations.AnnProtractorObject

Requirements

Target Platforms: Microsoft .NET Framework 2.0, Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also

Leadtools.Annotations requires a Document or Medical toolkit license and unlock key. For more information, refer to: Raster Pro/Document/Medical Features