public static void SetEnabled(string tabName, string panelUID, string buttonUID, bool enabled) { RibbonTabCollection oTabs = Autodesk.Windows.ComponentManager.Ribbon.Tabs; foreach (RibbonTab oTab in oTabs) { if (oTab.Title == tabName) { RibbonPanelCollection bPans = oTab.Panels; foreach (RibbonPanel oPanel in bPans) { if (oPanel.UID == panelUID) { foreach (RibbonItem item in oPanel.Source.Items) { if (item.UID == buttonUID) { item.IsEnabled = enabled; } } } } break; } } }
public static void modifyRibbon(string strTabName, string strPanelUID, string strButtonUID, bool bEnable) { RibbonTabCollection oTabs = Autodesk.Windows.ComponentManager.Ribbon.Tabs; foreach (RibbonTab oTab in oTabs) { if (oTab.Title == strTabName) { RibbonPanelCollection bPans = oTab.Panels; foreach (RibbonPanel oPanel in bPans) { if (oPanel.UID == strPanelUID) { foreach (RibbonItem item in oPanel.Source.Items) { if (item.UID == strButtonUID) { item.IsEnabled = bEnable; } } } } break; } } }
public RibbonTab() { _panels = new RibbonPanelCollection(this); //Initialize the ToolTip for this Item _TT = new RibbonToolTip(this); _TT.InitialDelay = 100; _TT.AutomaticDelay = 800; _TT.AutoPopDelay = 8000; _TT.UseAnimation = true; _TT.Active = false; _TT.Popup += _TT_Popup; }
public RibbonTab() { _panels = new RibbonPanelCollection(this); //Initialize the ToolTip for this Item _TT = new RibbonToolTip(this); _TT.InitialDelay = 100; _TT.AutomaticDelay = 800; _TT.AutoPopDelay = 8000; _TT.UseAnimation = true; _TT.Active = false; _TT.Popup += new PopupEventHandler(_TT_Popup); }
/// <summary> /// Creates a new RibbonTab /// </summary> public RibbonTab(Controls.Ribbon.Ribbon owner, string text) { _panels = new RibbonPanelCollection(owner, this); _text = text; }
public RibbonTab() { _panels = new RibbonPanelCollection(this); }