public ToolStripLineWidthPicker(Control parentControl) { _parentControl = parentControl; _lineWidthePicker = new OfficeLineWidthPicker(); _lineWidthePicker.PenWidthSelected += new EventHandler(PenWidth_PenWidthSelected); }
public override object EditValue(ITypeDescriptorContext context, IServiceProvider provider, object value) { IWindowsFormsEditorService wfes = provider.GetService( typeof(IWindowsFormsEditorService)) as IWindowsFormsEditorService; if (wfes != null) { gView.Framework.Symbology.UI.Controls.OfficeLineWidthPicker picker = new gView.Framework.Symbology.UI.Controls.OfficeLineWidthPicker(wfes); picker.Height = picker.PreferredHeight; wfes.DropDownControl(picker); return(picker.PenWidth != -1 ? picker.PenWidth : value); } return(value); }