LEADTOOLS Annotations for WPF and Silverlight (Leadtools.Windows.Annotations assembly) Send comments on this topic. | Back to Introduction - All Topics | Help Version 17.0.3.31
AnnLineObject Class
See Also  Members  
Leadtools.Windows.Annotations Namespace : AnnLineObject Class



The AnnLineObject Class supports WPF/Silverlight.

The AnnLineObject Class is available in LEADTOOLS Document and Medical Imaging toolkits.

Defines an annotation line object. Supported in Silverlight, Windows Phone 7

Object Model

AnnLineObject Class

Syntax

Visual Basic (Declaration) 
Public Class AnnLineObject 
   Inherits AnnObject
   Implements IAnnHeaderIAnnLineIAnnObject 
Visual Basic (Usage)Copy Code
Dim instance As AnnLineObject
C# 
public class AnnLineObject : AnnObject, IAnnHeaderIAnnLineIAnnObject  
C++/CLI 
public ref class AnnLineObject : public AnnObject, IAnnHeaderIAnnLineIAnnObject  

Example

For XAML example, refer to AnnGroupObject.

This example creates a new line object from 100, 200 to 400, 600 pixels with red stroke and then adds it to a container.

Visual BasicCopy Code
Private Sub AnnLineObject_AnnLineObject(ByVal container As AnnContainer)
   Dim line As AnnLineObject = New AnnLineObject()
   line.Stroke = Colors.Red
   line.StrokeThickness = 1.0
   line.Start = New Point(100, 100)
   line.End = New Point(400, 600)
   container.Children.Add(line)
End Sub
C#Copy Code
private void AnnLineObject_AnnLineObject(AnnContainer container)
{
   AnnLineObject line = new AnnLineObject();
   line.Stroke = Colors.Red;
   line.StrokeThickness = 1.0;
   line.Start = new Point(100, 200);
   line.End = new Point(400, 600);
   container.Children.Add(line);
}
SilverlightCSharpCopy Code
private void AnnLineObject_AnnLineObject(AnnContainer container)
{
   AnnLineObject line = new AnnLineObject();
   line.Stroke = Colors.Red;
   line.StrokeThickness = 1.0;
   line.Start = new Point(100, 200);
   line.End = new Point(400, 600);
   container.Children.Add(line);
}
SilverlightVBCopy Code
Private Sub AnnLineObject_AnnLineObject(ByVal container As AnnContainer)
   Dim line As AnnLineObject = New AnnLineObject()
   line.Stroke = Colors.Red
   line.StrokeThickness = 1.0
   line.Start = New Point(100, 200)
   line.End = New Point(400, 600)
   container.Children.Add(line)
End Sub

Remarks

The line annotation object is a simple line that has a start point, an end point and a stroke. For more information about the line annotation object refer to AnnLineObject for WPF. For more information about the automated line annotation object, refer to WPF Annotation Objects - Automated Features.

Inheritance Hierarchy

System.Object
   System.Windows.Threading.DispatcherObject
      System.Windows.DependencyObject
         Leadtools.Windows.Annotations.AnnObject
            Leadtools.Windows.Annotations.AnnLineObject
               Leadtools.Windows.Annotations.AnnPointerObject
               Leadtools.Windows.Annotations.AnnRulerObject

Requirements

Target Platforms: Silverlight 3.0, Windows XP, Windows Server 2003 family, Windows Server 2008 family, Windows Vista, Windows 7, MAC OS/X (Intel Only)

See Also

AnnLineObject requires a Document/Medical product license and unlock key. For more information, refer to: Imaging Pro/Document/Medical Features and Unlocking Special LEAD Features.