Imports Leadtools.WinForms
Imports Leadtools
Imports Leadtools.Codecs
Imports Leadtools.ImageProcessing.Color
Imports Leadtools.Drawing
Private Sub viewer_InteractiveRegionEllipse(ByVal sender As Object, ByVal e As RasterViewerRectangleEventArgs)
Console.WriteLine("InteractiveRegionEllipse: e.Rectangle {0}, e.Status {1}, e.Cancel {2}", e.Rectangle, e.Status, e.Cancel)
End Sub
Public Sub RasterImageViewer_InteractiveRegionEllipse(ByVal viewer As RasterImageViewer)
viewer.InteractiveMode = RasterViewerInteractiveMode.Region
viewer.InteractiveRegionType = RasterViewerInteractiveRegionType.Ellipse
AddHandler viewer.InteractiveRegionEllipse, AddressOf viewer_InteractiveRegionEllipse
' Draw the mouse on image to draw an elliptical region
' After you are done, you must remove the event handler as in below
'
' viewer.InteractiveRegionEllipse -= new EventHandler<RasterViewerRectangleEventArgs>(viewer_InteractiveRegionEllipse);
End Sub
using Leadtools.WinForms;
using Leadtools;
using Leadtools.Codecs;
using Leadtools.ImageProcessing.Color;
using Leadtools.Drawing;
private void viewer_InteractiveRegionEllipse(object sender, RasterViewerRectangleEventArgs e)
{
Console.WriteLine("InteractiveRegionEllipse: e.Rectangle {0}, e.Status {1}, e.Cancel {2}", e.Rectangle, e.Status, e.Cancel);
}
public void RasterImageViewer_InteractiveRegionEllipse(RasterImageViewer viewer)
{
viewer.InteractiveMode = RasterViewerInteractiveMode.Region;
viewer.InteractiveRegionType = RasterViewerInteractiveRegionType.Ellipse;
viewer.InteractiveRegionEllipse += new EventHandler<RasterViewerRectangleEventArgs>(viewer_InteractiveRegionEllipse);
// Draw the mouse on image to draw an elliptical region
// After you are done, you must remove the event handler as in below
//
// viewer.InteractiveRegionEllipse -= new EventHandler<RasterViewerRectangleEventArgs>(viewer_InteractiveRegionEllipse);
}