private void OnShowDesignerButtonClicked(NEventArgs args) { NEditor editor = NDesigner.GetDesigner(m_ComboBox).CreateInstanceEditor(m_ComboBox); NEditorWindow window = NApplication.CreateTopLevelWindow <NEditorWindow>(); window.Editor = editor; window.Open(); }
void OnDimFillButtonClick(NEventArgs arg) { NEditorWindow.CreateForType <NFill>( (NFill)m_NumericDisplay1.DimFill.DeepClone(), null, OwnerWindow, false, OnDimFillEdited).Open(); }
/// <summary> /// Called when the Show Application StyleSheets is clicked - shows the NApplicaiton. /// </summary> /// <param name="arg1"></param> void OnShowApplicationStyleSheetsClick(NEventArgs arg1) { NDesigner designer = NDesigner.GetDesigner(NApplication.Desktop.OwnerDocument.StyleSheets); NEditor editor = designer.CreateInstanceEditor(NApplication.Desktop.OwnerDocument.StyleSheets); NEditorWindow window = new NEditorWindow(); window.RemoveFromParentOnClose = true; window.Editor = editor; NApplication.Desktop.Windows.Add(window); window.Open(); }
private void OnButtonClick(NEventArgs args) { NButton button = args.TargetNode as NButton; if (button == null) { return; } NDesigner designer = (NDesigner)button.Tag; NEditor editor = designer.CreateInstanceEditor(m_Node); NEditorWindow window = NApplication.CreateTopLevelWindow <NEditorWindow>(); window.Editor = editor; window.Modal = false; window.Open(); }
private void OnShowDesignerClick(NEventArgs args) { try { NNode node = (NNode)args.TargetNode.Tag; NEditorWindow editorWindow = NEditorWindow.CreateForInstance( node, null, OwnerWindow, null); if (node is NStyleNodeCollectionTree) { editorWindow.PreferredSize = new NSize(500, 360); } editorWindow.Open(); } catch (Exception ex) { NTrace.WriteException("OnShowDesignerClick failed.", ex); } }