LEADTOOLS Annotations (Leadtools.Annotations assembly)
LEAD Technologies, Inc

AnnCrossProductObject Class

Example 





Members 
Defines an annotation cross product object.
Object Model
AnnCrossProductObject ClassAnnRectangle StructureAnnBrush ClassAnnContainer ClassAnnPoint StructureAnnPoint StructureAnnFont ClassAnnLength StructureAnnGroupObject ClassAnnPoint StructureAnnFont ClassAnnPoint StructureAnnPoint StructureAnnPen ClassAnnPoint StructureAnnPoint StructureAnnPoint StructureAnnPoint StructureAnnLength StructureAnnUnitConverter Class
Syntax
'Declaration
 
<SerializableAttribute()>
Public Class AnnCrossProductObject 
   Inherits AnnObject
   Implements IAnnRulerObjectSystem.ICloneableSystem.IDisposableSystem.Runtime.Serialization.ISerializable 
'Usage
 
Dim instance As AnnCrossProductObject
function Leadtools.Annotations.AnnCrossProductObject()
Remarks

The cross-product annotation object consists of two rulers intersecting at right angles. The intersection point of a cross product object updates dynamically and can be obtained through the IntersectionPoint property.

For more information about the crossproduct annotation object refer to AnnCrossProductObject. For more information about the automated crossproduct annotation object, refer to Annotation Objects - Automated Features.

Example
 
Private Sub AnnCrossProductObject_AnnCrossProductObject(ByVal container As AnnContainer)
   Dim crossProduct As AnnCrossProductObject = New AnnCrossProductObject()
   crossProduct.Pen = New AnnPen(Color.Red, New AnnLength(1, AnnUnit.Pixel))
   crossProduct.Font = New AnnFont("Arial", New AnnLength(10, AnnUnit.Point), FontStyle.Regular)
   crossProduct.FirstStartPoint = New AnnPoint(5, 5, AnnUnit.Inch)
   crossProduct.FirstEndPoint = New AnnPoint(10, 10, AnnUnit.Inch)
   ' make this cross product symmetrical
   crossProduct.UpdateSecondPoints()
   ' update the intersection point
   crossProduct.UpdateIntersectionPoint()
   crossProduct.MeasurementUnit = AnnUnit.Inch
   crossProduct.TickMarksLength = New AnnLength(0.25F, AnnUnit.Inch)
   crossProduct.ShowTickMarks = True
   crossProduct.GaugeLength = New AnnLength(1.0F, AnnUnit.Inch)
   crossProduct.ShowGauge = True
   crossProduct.ShowLength = True
   crossProduct.Precision = 2
   container.Objects.Add(crossProduct)
   ' show the intersection point
   MessageBox.Show(String.Format("Intersection point is at: {0}", crossProduct.IntersectionPoint))
End Sub
private void AnnCrossProductObject_AnnCrossProductObject(AnnContainer container)
{
   AnnCrossProductObject crossProduct = new AnnCrossProductObject();
   crossProduct.Pen = new AnnPen(Color.Red, new AnnLength(1, AnnUnit.Pixel));
   crossProduct.Font = new AnnFont("Arial", new AnnLength(10, AnnUnit.Point), FontStyle.Regular);
   crossProduct.FirstStartPoint = new AnnPoint(5, 5, AnnUnit.Inch);
   crossProduct.FirstEndPoint = new AnnPoint(10, 10, AnnUnit.Inch);
   // make this cross product symmetrical
   crossProduct.UpdateSecondPoints();
   // update the intersection point
   crossProduct.UpdateIntersectionPoint();
   crossProduct.MeasurementUnit = AnnUnit.Inch;
   crossProduct.TickMarksLength = new AnnLength(0.25F, AnnUnit.Inch);
   crossProduct.ShowTickMarks = true;
   crossProduct.GaugeLength = new AnnLength(1.0F, AnnUnit.Inch);
   crossProduct.ShowGauge = true;
   crossProduct.ShowLength = true;
   crossProduct.Precision = 2;
   container.Objects.Add(crossProduct);
   // show the intersection point
   MessageBox.Show(String.Format("Intersection point is at: {0}", crossProduct.IntersectionPoint));
}
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

AnnCrossProductObject Members
Leadtools.Annotations Namespace

 

 


Products | Support | Contact Us | Copyright Notices

© 2006-2012 All Rights Reserved. LEAD Technologies, Inc.