本文整理汇总了C#中System.Windows.Forms.TextBox.PerformLayout方法的典型用法代码示例。如果您正苦于以下问题:C# TextBox.PerformLayout方法的具体用法?C# TextBox.PerformLayout怎么用?C# TextBox.PerformLayout使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.Windows.Forms.TextBox
的用法示例。
在下文中一共展示了TextBox.PerformLayout方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: helpButton_Click
private void helpButton_Click(object sender, EventArgs e)
{
Form legend = new Form();
legend.Icon = BIDSHelper.Resources.Common.BIDSHelper;
legend.Text = "Measure Group Health Check: Legend";
legend.MaximizeBox = false;
legend.MinimizeBox = false;
TextBox text = new TextBox();
text.Location = new System.Drawing.Point(2, 2);
text.Size = new System.Drawing.Size(500, 380);
text.Multiline = true;
StringBuilder sb = new StringBuilder();
sb.AppendLine("Columns:");
sb.AppendLine("Measure - The measure name");
sb.AppendLine("Aggregate - The aggregate function for that measure");
sb.AppendLine("Total - The aggregated value across all rows");
sb.AppendLine("Min - The minimum value from a single row");
sb.AppendLine("Max - The maximum value from a single row");
sb.AppendLine("Decimals? - Are there any values that have decimals? More than 4 decimals?");
sb.AppendLine("DSV - The datatype for the column in the data source view");
sb.AppendLine("Current - The current measure datatype");
sb.AppendLine("New - The recommended new measure datatype");
sb.AppendLine();
sb.AppendLine("Datatypes:");
foreach (MeasureGroupHealthCheckPlugin.MeasureDataTypeOption dataType in MeasureGroupHealthCheckPlugin.dataTypeOptions)
{
sb.Append(dataType.dataType.ToString()).Append("/").Append(dataType.type.Name);
sb.Append(" (").Append(dataType.displayMin).Append(" to ").Append(dataType.displayMax).Append(") ").AppendLine(dataType.limitations);
}
text.Text = sb.ToString();
text.ReadOnly = true;
text.Select(0, 0);
text.BorderStyle = BorderStyle.None;
text.PerformLayout();
legend.Controls.Add(text);
legend.Width = text.Width + 4;
legend.Height = text.Height + 4;
legend.MinimumSize = legend.Size;
legend.MaximumSize = legend.Size;
legend.SizeGripStyle = SizeGripStyle.Hide;
legend.ShowInTaskbar = false;
legend.StartPosition = FormStartPosition.CenterParent;
legend.FormBorderStyle = FormBorderStyle.Fixed3D;
legend.PerformLayout();
legend.ShowDialog();
legend.Dispose();
}