public AnnSelectionObject SelectionObject { get; set; }
Public Property SelectionObject As AnnSelectionObject
@property (nonatomic) LTAnnSelectionObject *selectionObject;
public AnnSelectionObject getSelectionObject()
public void setSelectionObject(AnnSelectionObject object)
public:
property AnnSelectionObject^ SelectionObject
{
AnnSelectionObject^ get()
void set(AnnSelectionObject^ value)
}
The AnnSelectionObject used by this AnnContainer. The default value is a new AnnSelectionObject instance with its Stroke set to a dark green AnnStroke object with length of 2. This value cannot be null.
The selection object is always in the container and contains a collection (AnnSelectionObject.SelectedObjects) that holds references to the objects that are in a selected state. This object is used by the automation framework when multiple objects are selected and when drawing the selection "rectangle".
The style of this selection object can be changed from the default (dark green stroke of length 2) or you can derive your own custom object from AnnSelectionObject and use set it in this property.
The objects inside SelectionObject.SelectedObjects must be objects that already exist in the container, the automation frameworks keep this data in synch, therefore, use the AnnAutomation.SelectObject and AnnAutomation.SelectObjects methods to select and unselect objects from the container.
For more information, refer to the automation section in Programming with LEADTOOLS Annotations and Working with Automated Annotations.
using LeadtoolsExamples.Common;
using Leadtools.Annotations.Automation;
using Leadtools.Annotations.Engine;
using Leadtools.Codecs;
using Leadtools.Annotations.WinForms;
public void AnnContainer_SelectionObject()
{
// Get the selection object automation and update its template
AnnAutomationObject autSelectionObject = _automation.Manager.FindObjectById(AnnObject.SelectObjectId);
// Change its template stroke
autSelectionObject.ObjectTemplate.SelectionStroke = AnnStroke.Create(AnnSolidColorBrush.Create("black"), LeadLengthD.Create(1));
Debug.WriteLine("Draw the selection object and see how the new stroke looks");
}
Help Collections
Raster .NET | C API | C++ Class Library | HTML5 JavaScript
Document .NET | C API | C++ Class Library | HTML5 JavaScript
Medical .NET | C API | C++ Class Library | HTML5 JavaScript
Medical Web Viewer .NET
Multimedia
Direct Show .NET | C API | Filters
Media Foundation .NET | C API | Transforms
Supported Platforms
.NET, Java, Android, and iOS/macOS Assemblies
Imaging, Medical, and Document
C API/C++ Class Libraries
Imaging, Medical, and Document
HTML5 JavaScript Libraries
Imaging, Medical, and Document