本文整理汇总了C#中System.Windows.Forms.PropertyGrid.ExpandAllGridItems方法的典型用法代码示例。如果您正苦于以下问题:C# PropertyGrid.ExpandAllGridItems方法的具体用法?C# PropertyGrid.ExpandAllGridItems怎么用?C# PropertyGrid.ExpandAllGridItems使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.Windows.Forms.PropertyGrid
的用法示例。
在下文中一共展示了PropertyGrid.ExpandAllGridItems方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: InitializeComponent
private void InitializeComponent()
{
propertyOptions = new PropertyGrid();
buttonOk = new Button();
buttonCancel = new Button();
panelTopMain = new Panel();
panelBottomMain = new Panel();
panelTopMain.SuspendLayout();
panelBottomMain.SuspendLayout();
base.SuspendLayout();
propertyOptions.CommandsVisibleIfAvailable = true;
propertyOptions.HelpVisible = false;
propertyOptions.LargeButtons = false;
propertyOptions.LineColor = SystemColors.ScrollBar;
propertyOptions.Location = new Point(8, 8);
propertyOptions.Name = "propertyOptions";
propertyOptions.PropertySort = PropertySort.Alphabetical;
propertyOptions.Dock = DockStyle.Fill;
propertyOptions.TabIndex = 0;
propertyOptions.Text = "PropertyGrid";
propertyOptions.ToolbarVisible = false;
propertyOptions.ViewBackColor = SystemColors.Window;
propertyOptions.ViewForeColor = SystemColors.WindowText;
propertyOptions.SelectedObject = Configuration.MasterConfig.Copy();
buttonOk.DialogResult = DialogResult.Cancel;
buttonOk.FlatStyle = FlatStyle.Popup;
buttonOk.Location = new Point(8, 5);
buttonOk.Name = "buttonOk";
buttonOk.Size = new Size(50, 20);
buttonOk.TabIndex = 1;
buttonOk.Text = "OK";
buttonOk.Click += new EventHandler(buttonOk_Click);
buttonCancel.DialogResult = DialogResult.Cancel;
buttonCancel.FlatStyle = FlatStyle.Popup;
buttonCancel.Location = new Point(70, 5);
buttonCancel.Name = "buttonCancel";
buttonCancel.Size = new Size(50, 20);
buttonCancel.TabIndex = 1;
buttonCancel.Text = "Cancel";
buttonCancel.Click += new EventHandler(buttonCancel_Click);
panelTopMain.BorderStyle = BorderStyle.None;
panelTopMain.Controls.AddRange(new Control[] {propertyOptions});
panelTopMain.Dock = DockStyle.Fill;
panelTopMain.Name = "panelTopMain";
panelTopMain.Size = new Size(0, 250);
panelTopMain.TabIndex = 0;
panelBottomMain.BorderStyle = BorderStyle.None;
panelBottomMain.Controls.AddRange(new Control[] {buttonOk, buttonCancel});
panelBottomMain.Dock = DockStyle.Bottom;
panelBottomMain.Size = new Size(0, 30);
panelBottomMain.Name = "panelBottomMain";
panelBottomMain.TabIndex = 1;
base.AcceptButton = buttonOk;
base.CancelButton = buttonCancel;
AutoScaleBaseSize = new Size(5, 13);
base.ClientSize = new Size(0x110, 0x12b);
base.Controls.AddRange(new Control[] {panelTopMain, panelBottomMain});
base.Name = "OptionDialog";
Text = "Options ";
panelTopMain.ResumeLayout(false);
panelBottomMain.ResumeLayout(false);
base.ResumeLayout(false);
propertyOptions.ExpandAllGridItems();
}