←Select platform

RubberStampButtonDropDownContextMenu Property

Summary

Gets or sets the context menu for the rubber stamp toolbar button of this AnnAutomationManager.

Syntax

C#
VB
C++
public ContextMenu RubberStampButtonDropDownContextMenu { get; set; } 
  
Public Property RubberStampButtonDropDownContextMenu As ContextMenu 
public: 
property ContextMenu^ RubberStampButtonDropDownContextMenu { 
   ContextMenu^ get(); 
   void set (    ContextMenu^ ); 
} 

Property Value

The context menu for the rubber stamp toolbar button of this AnnAutomationManager.

Remarks

The ToolBar can create a button for the rubber stamp objects. The value of this property is the context menu used when this button is left or right clicked.

You can directly manipulate (for more information, refer to Localization of LEADTOOLS for .NET WPF Annotations Automation) this context menu or set your own System.Windows.Controls.ContextMenu derived class if desired. For a list of available rubber stamp types, refer to the AnnRubberStampType enumeration.

Example

This example disables the "Void" rubber stamp type.

C#
VB
using Leadtools.Windows.Controls; 
using Leadtools.Windows.Annotations; 
using Leadtools.Demos; 
using Leadtools.Help; 
 
private void AnnAutomationManager_RubberStampButtonDropDownContextMenu(AnnAutomationManager manager) 
{ 
   foreach (MenuItem item in manager.RubberStampButtonDropDownContextMenu.Items) 
   { 
      if (string.Compare((string)item.Header, "Void", false) == 0) 
         item.IsEnabled = false; 
   } 
} 
Imports Leadtools.Windows.Controls 
Imports Leadtools.Windows.Annotations 
 
Private Sub AnnAutomationManager_RubberStampButtonDropDownContextMenu(ByVal manager As AnnAutomationManager) 
   For Each item As MenuItem In manager.RubberStampButtonDropDownContextMenu.Items 
      If String.Compare(CStr(item.Header), "Void", False) = 0 Then 
         item.IsEnabled = False 
      End If 
   Next item 
End Sub 

Requirements

Target Platforms

Help Version 19.0.2017.10.27
Products | Support | Contact Us | Copyright Notices
© 1991-2017 LEAD Technologies, Inc. All Rights Reserved.

Leadtools.Windows.Annotations Assembly