The AnnPointObject Class supports WPF/Silverlight.
The AnnPointObject Class is available in LEADTOOLS Document and Medical Imaging toolkits.
Defines an annotation point object.
Supported in Silverlight, Windows Phone 7
Object Model
Syntax
Example
This example adds a new point object to a container.
Visual Basic | Copy Code |
---|
Private Sub AnnPointObject_AnnPointObject(ByVal viewer As ImageViewer, ByVal container As AnnContainer)
Dim point As AnnPointObject = New AnnPointObject()
point.CenterPoint = New System.Windows.Point(100, 100)
point.ShowPicture = True
' default picture, no need to change anything
container.Children.Add(point)
MessageBox.Show("Picture")
' show with a radius
point.Radius = 16.0
point.Stroke = Colors.Red
point.StrokeThickness = 1.0
point.ShowPicture = False
MessageBox.Show("No picture")
End Sub |
C# | Copy Code |
---|
private void AnnPointObject_AnnPointObject(ImageViewer viewer, AnnContainer container)
{
AnnPointObject point = new AnnPointObject();
point.CenterPoint = new Point(100, 100);
point.ShowPicture = true;
// default picture, no need to change anything
container.Children.Add(point);
MessageBox.Show("Picture");
// show with a radius
point.Radius = 16.0;
point.Stroke = Colors.Red;
point.StrokeThickness = 1.0;
point.ShowPicture = false;
MessageBox.Show("No picture");
} |
SilverlightCSharp | Copy Code |
---|
private void AnnPointObject_AnnPointObject(ImageViewer viewer, AnnContainer container)
{
AnnPointObject point = new AnnPointObject();
point.CenterPoint = new Point(100, 100);
point.ShowPicture = true;
// default picture, no need to change anything
container.Children.Add(point);
MessageBox.Show("Picture");
// show with a radius
point.Radius = 16.0;
point.Stroke = Colors.Red;
point.StrokeThickness = 1.0;
point.ShowPicture = false;
MessageBox.Show("No picture");
} |
SilverlightVB | Copy Code |
---|
Private Sub AnnPointObject_AnnPointObject(ByVal viewer As ImageViewer, ByVal container As AnnContainer)
Dim point As AnnPointObject = New AnnPointObject()
point.CenterPoint = New Point(100, 100)
point.ShowPicture = True
' default picture, no need to change anything
container.Children.Add(point)
MessageBox.Show("Picture")
' show with a radius
point.Radius = 16.0
point.Stroke = Colors.Red
point.StrokeThickness = 1.0
point.ShowPicture = False
MessageBox.Show("No picture")
End Sub |
XAML | Copy Code |
---|
<Window x:Class="WPFSamples.AnnPointObject" Title="Leadtools.Windows.Annotations" Height="600" Width="800" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:Leadtools_Windows_Annotations="clr-namespace:Leadtools.Windows.Annotations;assembly=Leadtools.Windows.Annotations">
<Leadtools_Windows_Annotations:AnnPointObject Stroke="Blue" StrokeThickness="3.0" ShowPicture="False" Picture="{x:Null}" Radius="25" CenterPoint="100,100" Header="Point Object" />
</Window> |
Remarks
Inheritance Hierarchy
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