Determines if the control is currently performing an interactive operation.
public virtual bool IsInteractiveModeBusy {get;}
Public Overridable ReadOnly Property IsInteractiveModeBusy As Boolean
public:
virtual property bool IsInteractiveModeBusy {
bool get();
}
true if the control is currently performing an interactive operation, false otherwise.
The type of interactive user operation is determined by the InteractiveMode property.
This example sets the interactive mode to draw a rectangular region. If the mouse is dragged up or to the left, the interactive mode is cancelled.
Imports Leadtools.Windows.Controls
Public Sub BitmapSourceViewer_IsInteractiveModeBusy(ByVal viewer As ImageViewer)
AddHandler viewer.InteractiveUserRectangle, AddressOf viewer_InteractiveUserRectangle
viewer.InteractiveMode = InteractiveMode.UserRectangle
MessageBox.Show("Interactive mode set to draw a rectangular geometry." & Constants.vbLf & "If mouse is dragged up or to the left, interactive mode is cancelled")
End Sub
Private Sub viewer_InteractiveUserRectangle(ByVal sender As Object, ByVal e As RectangleInteractiveEventArgs)
Console.WriteLine("" & e.Status)
Dim viewer As ImageViewer = TryCast(sender, ImageViewer)
Dim ee As RectangleInteractiveEventArgs = New RectangleInteractiveEventArgs(e.Status, e.Bounds)
If e.Status = InteractiveModeStatus.End Then
e.Cancel = True
If (Not viewer.IsInteractiveModeBusy) Then
MessageBox.Show("Interactive mode (Rectangular geometry) cancelled")
viewer.InteractiveMode = InteractiveMode.None
End If
End If
Console.WriteLine("" & e.Bounds.Left & ", " & e.Bounds.Top & ", " & e.Bounds.Right & ", " & e.Bounds.Bottom)
End Sub
using Leadtools.Help;
using Leadtools.Windows.Controls;
public void BitmapSourceViewer_IsInteractiveModeBusy(ImageViewer viewer)
{
viewer.InteractiveUserRectangle += new EventHandler<RectangleInteractiveEventArgs>(viewer_InteractiveUserRectangle);
viewer.InteractiveMode = InteractiveMode.UserRectangle;
MessageBox.Show("Interactive mode set to draw a rectangular geometry.\nIf mouse is dragged up or to the left, interactive mode is cancelled");
}
void viewer_InteractiveUserRectangle(object sender, RectangleInteractiveEventArgs e)
{
Console.WriteLine(@"" + e.Status);
ImageViewer viewer = sender as ImageViewer;
RectangleInteractiveEventArgs ee = new RectangleInteractiveEventArgs(e.Status, e.Bounds);
if (e.Status == InteractiveModeStatus.End)
{
e.Cancel = true;
if (!viewer.IsInteractiveModeBusy)
{
MessageBox.Show("Interactive mode (Rectangular geometry) cancelled");
viewer.InteractiveMode = InteractiveMode.None;
}
}
Console.WriteLine(@"" + e.Bounds.Left + ", " + e.Bounds.Top + ", " + e.Bounds.Right + ", " + e.Bounds.Bottom);
}
using Leadtools.Help;
using Leadtools.Windows.Controls;
public void BitmapSourceViewer_IsInteractiveModeBusy(ImageViewer viewer)
{
viewer.InteractiveUserRectangle += new EventHandler<RectangleInteractiveEventArgs>(viewer_InteractiveUserRectangle);
viewer.InteractiveMode = InteractiveMode.UserRectangle;
MessageBox.Show("Interactive mode set to draw a rectangular geometry.\nIf mouse is dragged up or to the left, interactive mode is cancelled");
}
void viewer_InteractiveUserRectangle(object sender, RectangleInteractiveEventArgs e)
{
Console.WriteLine(@"" + e.Status);
ImageViewer viewer = sender as ImageViewer;
RectangleInteractiveEventArgs ee = new RectangleInteractiveEventArgs(e.Status, e.Bounds);
if (e.Status == InteractiveModeStatus.End)
{
e.Cancel = true;
if (!viewer.IsInteractiveModeBusy)
{
MessageBox.Show("Interactive mode (Rectangular geometry) cancelled");
viewer.InteractiveMode = InteractiveMode.None;
}
}
Console.WriteLine(@"" + e.Bounds.Left + ", " + e.Bounds.Top + ", " + e.Bounds.Right + ", " + e.Bounds.Bottom);
}
Imports Leadtools
Imports Leadtools.Windows.Controls
Public Sub BitmapSourceViewer_IsInteractiveModeBusy(ByVal viewer As ImageViewer)
AddHandler viewer.InteractiveUserRectangle, AddressOf viewer_InteractiveUserRectangle
viewer.InteractiveMode = InteractiveMode.UserRectangle
MessageBox.Show("Interactive mode set to draw a rectangular geometry." & Constants.vbLf & _
"If mouse is dragged up or to the left, interactive mode is cancelled")
End Sub
Private Sub viewer_InteractiveUserRectangle(ByVal sender As Object, ByVal e As RectangleInteractiveEventArgs)
Console.WriteLine("" & e.Status)
Dim viewer As ImageViewer = TryCast(sender, ImageViewer)
Dim ee As RectangleInteractiveEventArgs = New RectangleInteractiveEventArgs(e.Status, e.Bounds)
If e.Status = InteractiveModeStatus.End Then
e.Cancel = True
If (Not viewer.IsInteractiveModeBusy) Then
MessageBox.Show("Interactive mode (Rectangular geometry) cancelled")
viewer.InteractiveMode = InteractiveMode.None
End If
End If
Console.WriteLine("" & e.Bounds.Left & ", " & e.Bounds.Top & ", " & e.Bounds.Right & ", " & e.Bounds.Bottom)
End Sub
Products |
Support |
Feedback: IsInteractiveModeBusy Property - Leadtools.Windows.Controls |
Introduction |
Help Version 19.0.2017.3.22
|
Raster .NET | C API | C++ Class Library | JavaScript HTML5
Document .NET | C API | C++ Class Library | JavaScript HTML5
Medical .NET | C API | C++ Class Library | JavaScript HTML5
Medical Web Viewer .NET
Your email has been sent to support! Someone should be in touch! If your matter is urgent please come back into chat.
Chat Hours:
Monday - Friday, 8:30am to 6pm ET
Thank you for your feedback!
Please fill out the form again to start a new chat.
All agents are currently offline.
Chat Hours:
Monday - Friday
8:30AM - 6PM EST
To contact us please fill out this form and we will contact you via email.