PowerTools PlusPak for Windows Forms 8.0J
GcTableLayoutContainer クラス
メンバ  使用例 

行と列で構成されたグリッドにその内容を動的にレイアウトするパネルを表します。
構文
Public Class GcTableLayoutContainer 
   Inherits System.Windows.Forms.Panel
public class GcTableLayoutContainer : System.Windows.Forms.Panel 
解説

GcTableLayoutContainer コントロールは、その内容をグリッドに配置します。レイアウトは設計時にも実行時にも行われるため、アプリケーション環境の変更に応じてレイアウトを動的に変更できます。パネル上のコントロールは比例的にサイズ変更できるので、親コントロールのサイズ変更やローカリゼーションによるテキストの長さの変更などに対応できます。

任意の Windows Forms コントロールを GcTableLayoutContainer コントロールの子にすることができます。これには他の GcTableLayoutContainer のインスタンスも含まれます。これにより、実行時の変更に合わせた高度なレイアウトを構築できます。

GcTableLayoutContainer コントロールが子コントロールでいっぱいになった後の拡張方向(水平または垂直)を制御することもできます。デフォルトでは、GcTableLayoutContainer コントロールは行を追加することによって下方向に拡張します。

行と列をデフォルトとは異なるように動作させる場合は、Rows プロパティと Columns プロパティを使用して行と列のプロパティを制御できます。行および列のプロパティは個別に設定できます。

GcTableLayoutContainer コントロールは、Cell、Column、Row の各プロパティを子コントロールに追加します。

GcTableLayoutContainer コントロールは、その内容をグリッドに配置します。レイアウト機能のほとんどは MS TableLayoutPanel と同じですが、重要な違いが 3 つあります。

GcTableLayoutContainer コントロールのレイアウト計算の対象となるのは、System.Windows.Forms.Control.Visible プロパティが true に設定されているコントロールだけです。

GcTableLayoutContainer は設計時に設計することを強く推奨します。この設計作業は非常に簡単であり、そうすることで GcTableLayoutContainer を構築するために多くのコードを記述する必要がなくなります。

使用例

次のサンプルコードは、GcTableLayoutContainer のほとんどの機能の使用方法と、関連するいくつかのプロパティの設定例を示します。

次のサンプルコードは、GcTableLayoutContainer でマージを実行する方法を示します。

次のサンプルコードは、GcTableLayoutContainer のセルの境界線を設定する方法を示します。

次のサンプルコードは、GcTableLayoutContainer のセルの背景プロパティを設定する方法を示します。

private void CreateFirstGcTableLayoutContainer()
{
    Border border1 = new Border();
    GcTableLayoutContainer gcTableLayoutContainer1 = new GcTableLayoutContainer();
    TableColumn tableColumn1 = new TableColumn();
    TableColumn tableColumn2 = new TableColumn();
    TableRow tableRow1 = new TableRow();
    TableRow tableRow2 = new TableRow();
    Button button1 = new Button();
    Button button2 = new Button();
    Button button3 = new Button();
    Button button4 = new Button();
    ((System.ComponentModel.ISupportInitialize)(gcTableLayoutContainer1)).BeginInit();
    gcTableLayoutContainer1.SuspendLayout();
    SuspendLayout();
    // 
    // gcTableLayoutContainer1
    // 
    border1.Outline = new Line(LineStyle.Thin, Color.Black);
    gcTableLayoutContainer1.Border = border1;
    gcTableLayoutContainer1.Columns.AddRange(new TableColumn[] {
    tableColumn1,
    tableColumn2});
    gcTableLayoutContainer1.Rows.AddRange(new TableRow[] {
    tableRow1,
    tableRow2});
    gcTableLayoutContainer1.Controls.Add(button1, 0, 0);
    gcTableLayoutContainer1.Controls.Add(button2, 1, 0);
    gcTableLayoutContainer1.Controls.Add(button3, 0, 1);
    gcTableLayoutContainer1.Controls.Add(button4, 1, 1);
    gcTableLayoutContainer1.Location = new Point(10, 10);
    gcTableLayoutContainer1.Name = "gcTableLayoutContainer1";
    gcTableLayoutContainer1.Size = new Size(200, 200);
    gcTableLayoutContainer1.TabIndex = 0;
    // 
    // tableColumn1
    // 
    tableColumn1.SizeType = SizeType.Percent;
    tableColumn1.Width = 50F;
    // 
    // tableColumn2
    // 
    tableColumn2.SizeType = SizeType.Percent;
    tableColumn2.Width = 50F;
    // 
    // tableRow1
    // 
    tableRow1.Height = 50F;
    tableRow1.SizeType = SizeType.Percent;
    // 
    // tableRow2
    // 
    tableRow2.Height = 50F;
    tableRow2.SizeType = SizeType.Percent;
    // 
    // button1
    // 
    button1.Location = new Point(6, 6);
    button1.Name = "button1";
    button1.Size = new Size(75, 23);
    button1.TabIndex = 0;
    button1.Text = "FirstCell";
    button1.UseVisualStyleBackColor = true;
    // 
    // button2
    // 
    button2.Location = new Point(104, 6);
    button2.Name = "button2";
    button2.Size = new Size(75, 23);
    button2.TabIndex = 1;
    button2.Text = "SecondCell";
    button2.UseVisualStyleBackColor = true;
    // 
    // button3
    // 
    button3.Location = new Point(6, 54);
    button3.Name = "button3";
    button3.Size = new Size(75, 23);
    button3.TabIndex = 2;
    button3.Text = "ThirdCell";
    button3.UseVisualStyleBackColor = true;
    // 
    // button4
    // 
    button4.Location = new Point(104, 54);
    button4.Name = "button4";
    button4.Size = new Size(75, 23);
    button4.TabIndex = 3;
    button4.Text = "FourthCell";
    button4.UseVisualStyleBackColor = true;

    ((System.ComponentModel.ISupportInitialize)(gcTableLayoutContainer1)).EndInit();
    gcTableLayoutContainer1.ResumeLayout(true);
    this.Controls.Add(gcTableLayoutContainer1);
}
Private Sub CreateFirstGcTableLayoutContainer()
    Dim border1 As New Border()
    Dim gcTableLayoutContainer1 As New GcTableLayoutContainer()
    Dim tableColumn1 As New TableColumn()
    Dim tableColumn2 As New TableColumn()
    Dim tableRow1 As New TableRow()
    Dim tableRow2 As New TableRow()
    Dim button1 As New Button()
    Dim button2 As New Button()
    Dim button3 As New Button()
    Dim button4 As New Button()
    CType((gcTableLayoutContainer1), System.ComponentModel.ISupportInitialize).BeginInit()
    gcTableLayoutContainer1.SuspendLayout()
    SuspendLayout()
    ' 
    ' gcTableLayoutContainer1
    ' 
    border1.Outline = New Line(LineStyle.Thin, Color.Black)
    gcTableLayoutContainer1.Border = border1
    gcTableLayoutContainer1.Columns.AddRange(New TableColumn() {tableColumn1, tableColumn2})
    gcTableLayoutContainer1.Rows.AddRange(New TableRow() {tableRow1, tableRow2})
    gcTableLayoutContainer1.Controls.Add(button1, 0, 0)
    gcTableLayoutContainer1.Controls.Add(button2, 1, 0)
    gcTableLayoutContainer1.Controls.Add(button3, 0, 1)
    gcTableLayoutContainer1.Controls.Add(button4, 1, 1)
    gcTableLayoutContainer1.Location = New Point(10, 10)
    gcTableLayoutContainer1.Name = "gcTableLayoutContainer1"
    gcTableLayoutContainer1.Size = New Size(200, 200)
    gcTableLayoutContainer1.TabIndex = 0
    ' 
    ' tableColumn1
    ' 
    tableColumn1.SizeType = SizeType.Percent
    tableColumn1.Width = 50.0F
    ' 
    ' tableColumn2
    ' 
    tableColumn2.SizeType = SizeType.Percent
    tableColumn2.Width = 50.0F
    ' 
    ' tableRow1
    ' 
    tableRow1.Height = 50.0F
    tableRow1.SizeType = SizeType.Percent
    ' 
    ' tableRow2
    ' 
    tableRow2.Height = 50.0F
    tableRow2.SizeType = SizeType.Percent
    ' 
    ' button1
    ' 
    button1.Location = New Point(6, 6)
    button1.Name = "button1"
    button1.Size = New Size(75, 23)
    button1.TabIndex = 0
    button1.Text = "FirstCell"
    button1.UseVisualStyleBackColor = True
    ' 
    ' button2
    ' 
    button2.Location = New Point(104, 6)
    button2.Name = "button2"
    button2.Size = New Size(75, 23)
    button2.TabIndex = 1
    button2.Text = "SecondCell"
    button2.UseVisualStyleBackColor = True
    ' 
    ' button3
    ' 
    button3.Location = New Point(6, 54)
    button3.Name = "button3"
    button3.Size = New Size(75, 23)
    button3.TabIndex = 2
    button3.Text = "ThirdCell"
    button3.UseVisualStyleBackColor = True
    ' 
    ' button4
    ' 
    button4.Location = New Point(104, 54)
    button4.Name = "button4"
    button4.Size = New Size(75, 23)
    button4.TabIndex = 3
    button4.Text = "FourthCell"
    button4.UseVisualStyleBackColor = True

    CType((gcTableLayoutContainer1), System.ComponentModel.ISupportInitialize).EndInit()
    gcTableLayoutContainer1.ResumeLayout(True)
    Me.Controls.Add(gcTableLayoutContainer1)
End Sub
private void CreateMergedCell()
{
    GcTableLayoutContainer gcTableLayoutContainer1;
    TableColumn tableColumn1;
    TableColumn tableColumn2;
    TableColumn tableColumn3;
    TableColumn tableColumn4;
    Label label1;
    TableRow tableRow1;
    TableRow tableRow2;
    TableRow tableRow3;
    TableRow tableRow4;
    Label label2;
    Label label3;

    Border border1 = new Border();
    gcTableLayoutContainer1 = new GcTableLayoutContainer();
    tableColumn1 = new TableColumn();
    tableColumn2 = new TableColumn();
    tableRow1 = new TableRow();
    tableRow2 = new TableRow();
    tableColumn3 = new TableColumn();
    tableColumn4 = new TableColumn();
    tableRow3 = new TableRow();
    tableRow4 = new TableRow();
    label1 = new Label();
    label2 = new Label();
    label3 = new Label();
    ((System.ComponentModel.ISupportInitialize)(gcTableLayoutContainer1)).BeginInit();
    gcTableLayoutContainer1.SuspendLayout();
    // 
    // gcTableLayoutContainer1
    // 
    border1.Outline = new Line(LineStyle.Thin, Color.Black);
    gcTableLayoutContainer1.Border = border1;
    gcTableLayoutContainer1.Columns.AddRange(new TableColumn[] {
    tableColumn1,
    tableColumn2,
    tableColumn3,
    tableColumn4});
    gcTableLayoutContainer1.Rows.AddRange(new TableRow[] {
    tableRow1,
    tableRow2,
    tableRow3,
    tableRow4});
    gcTableLayoutContainer1.CellInfos.AddRange(new CellInfo[] {
    new CellInfo(new CellPosition(0, 1), 2, 2),
    new CellInfo(new CellPosition(2, 2), 2, 2),
    new CellInfo(new CellPosition(2, 0), 2, 1)});
    gcTableLayoutContainer1.Controls.Add(label1, 0, 1);
    gcTableLayoutContainer1.Controls.Add(label2, 2, 2);
    gcTableLayoutContainer1.Controls.Add(label3, 2, 0);
    gcTableLayoutContainer1.Location = new Point(0, 0);
    gcTableLayoutContainer1.Name = "gcTableLayoutContainer1";
  
    gcTableLayoutContainer1.Size = new Size(250, 250);
    gcTableLayoutContainer1.TabIndex = 0;
    // 
    // tableColumn1
    // 
    tableColumn1.SizeType = SizeType.Percent;
    tableColumn1.Width = 50F;
    // 
    // tableColumn2
    // 
    tableColumn2.SizeType = SizeType.Percent;
    tableColumn2.Width = 50F;
    // 
    // tableRow1
    // 
    tableRow1.Height = 50F;
    tableRow1.SizeType = SizeType.Percent;
    // 
    // tableRow2
    // 
    tableRow2.Height = 50F;
    tableRow2.SizeType = SizeType.Percent;
    // 
    // tableColumn3
    // 
    tableColumn3.SizeType = SizeType.Percent;
    tableColumn3.Width = 50F;
    // 
    // tableColumn4
    // 
    tableColumn4.SizeType = SizeType.Percent;
    tableColumn4.Width = 50F;
    // 
    // tableRow3
    // 
    tableRow3.Height = 50F;
    tableRow3.SizeType = SizeType.Percent;
    // 
    // tableRow4
    // 
    tableRow4.Height = 50F;
    tableRow4.SizeType = SizeType.Percent;
    // 
    // label1
    // 
    label1.BackColor = Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(192)))));
    label1.Dock = DockStyle.Fill;
    label1.Location = new Point(3, 57);
    label1.Margin = new Padding(0);
    label1.Name = "label1";
    label1.Size = new Size(153, 105);
    label1.TabIndex = 0;
    label1.Text = "MergedCell1";
    label1.TextAlign = ContentAlignment.MiddleCenter;
    // 
    // label2
    // 
    label2.AutoSize = true;
    label2.BackColor = Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(255)))), ((int)(((byte)(255)))));
    label2.Dock = DockStyle.Fill;
    label2.Location = new Point(159, 111);
    label2.Margin = new Padding(0);
    label2.Name = "label2";
    label2.Size = new Size(156, 106);
    label2.TabIndex = 0;
    label2.Text = "MergedCell3";
    label2.TextAlign = ContentAlignment.MiddleCenter;
    // 
    // label3
    // 
    label3.BackColor = Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(192)))), ((int)(((byte)(255)))));
    label3.Dock = DockStyle.Fill;
    label3.Location = new Point(159, 3);
    label3.Margin = new Padding(0);
    label3.Name = "label3";
    label3.Size = new Size(156, 51);
    label3.TabIndex = 1;
    label3.Text = "MergedCell2";

    ((System.ComponentModel.ISupportInitialize)(gcTableLayoutContainer1)).EndInit();
    gcTableLayoutContainer1.ResumeLayout(false);
    gcTableLayoutContainer1.Dock = DockStyle.Fill;
    this.Controls.Add(gcTableLayoutContainer1);
    gcTableLayoutContainer1.PerformLayout();
}
Private Sub CreateMergedCell()
    Dim gcTableLayoutContainer1 As GcTableLayoutContainer
    Dim tableColumn1 As TableColumn
    Dim tableColumn2 As TableColumn
    Dim tableColumn3 As TableColumn
    Dim tableColumn4 As TableColumn
    Dim label1 As Label
    Dim tableRow1 As TableRow
    Dim tableRow2 As TableRow
    Dim tableRow3 As TableRow
    Dim tableRow4 As TableRow
    Dim label2 As Label
    Dim label3 As Label

    Dim border1 As New Border()
    gcTableLayoutContainer1 = New GcTableLayoutContainer()
    tableColumn1 = New TableColumn()
    tableColumn2 = New TableColumn()
    tableRow1 = New TableRow()
    tableRow2 = New TableRow()
    tableColumn3 = New TableColumn()
    tableColumn4 = New TableColumn()
    tableRow3 = New TableRow()
    tableRow4 = New TableRow()
    label1 = New Label()
    label2 = New Label()
    label3 = New Label()
    CType((gcTableLayoutContainer1), System.ComponentModel.ISupportInitialize).BeginInit()
    gcTableLayoutContainer1.SuspendLayout()
    ' 
    ' gcTableLayoutContainer1
    ' 
    border1.Outline = New Line(LineStyle.Thin, Color.Black)
    gcTableLayoutContainer1.Border = border1
    gcTableLayoutContainer1.Columns.AddRange(New TableColumn() {tableColumn1, tableColumn2, tableColumn3, tableColumn4})
    gcTableLayoutContainer1.Rows.AddRange(New TableRow() {tableRow1, tableRow2, tableRow3, tableRow4})
    gcTableLayoutContainer1.CellInfos.AddRange(New CellInfo() {New CellInfo(New CellPosition(0, 1), 2, 2), New CellInfo(New CellPosition(2, 2), 2, 2), New CellInfo(New CellPosition(2, 0), 2, 1)})
    gcTableLayoutContainer1.Controls.Add(label1, 0, 1)
    gcTableLayoutContainer1.Controls.Add(label2, 2, 2)
    gcTableLayoutContainer1.Controls.Add(label3, 2, 0)
    gcTableLayoutContainer1.Location = New Point(0, 0)
    gcTableLayoutContainer1.Name = "gcTableLayoutContainer1"

    gcTableLayoutContainer1.Size = New Size(250, 250)
    gcTableLayoutContainer1.TabIndex = 0
    ' 
    ' tableColumn1
    ' 
    tableColumn1.SizeType = SizeType.Percent
    tableColumn1.Width = 50.0F
    ' 
    ' tableColumn2
    ' 
    tableColumn2.SizeType = SizeType.Percent
    tableColumn2.Width = 50.0F
    ' 
    ' tableRow1
    ' 
    tableRow1.Height = 50.0F
    tableRow1.SizeType = SizeType.Percent
    ' 
    ' tableRow2
    ' 
    tableRow2.Height = 50.0F
    tableRow2.SizeType = SizeType.Percent
    ' 
    ' tableColumn3
    ' 
    tableColumn3.SizeType = SizeType.Percent
    tableColumn3.Width = 50.0F
    ' 
    ' tableColumn4
    ' 
    tableColumn4.SizeType = SizeType.Percent
    tableColumn4.Width = 50.0F
    ' 
    ' tableRow3
    ' 
    tableRow3.Height = 50.0F
    tableRow3.SizeType = SizeType.Percent
    ' 
    ' tableRow4
    ' 
    tableRow4.Height = 50.0F
    tableRow4.SizeType = SizeType.Percent
    ' 
    ' label1
    ' 
    label1.BackColor = Color.FromArgb(CType(CType((192), Byte), Integer), CType(CType((255), Byte), Integer), CType(CType((192), Byte), Integer))
    label1.Dock = DockStyle.Fill
    label1.Location = New Point(3, 57)
    label1.Margin = New Padding(0)
    label1.Name = "label1"
    label1.Size = New Size(153, 105)
    label1.TabIndex = 0
    label1.Text = "MergedCell1"
    label1.TextAlign = ContentAlignment.MiddleCenter
    ' 
    ' label2
    ' 
    label2.AutoSize = True
    label2.BackColor = Color.FromArgb(CType(CType((128), Byte), Integer), CType(CType((255), Byte), Integer), CType(CType((255), Byte), Integer))
    label2.Dock = DockStyle.Fill
    label2.Location = New Point(159, 111)
    label2.Margin = New Padding(0)
    label2.Name = "label2"
    label2.Size = New Size(156, 106)
    label2.TabIndex = 0
    label2.Text = "MergedCell3"
    label2.TextAlign = ContentAlignment.MiddleCenter
    ' 
    ' label3
    ' 
    label3.BackColor = Color.FromArgb(CType(CType((192), Byte), Integer), CType(CType((192), Byte), Integer), CType(CType((255), Byte), Integer))
    label3.Dock = DockStyle.Fill
    label3.Location = New Point(159, 3)
    label3.Margin = New Padding(0)
    label3.Name = "label3"
    label3.Size = New Size(156, 51)
    label3.TabIndex = 1
    label3.Text = "MergedCell2"

    CType((gcTableLayoutContainer1), System.ComponentModel.ISupportInitialize).EndInit()
    gcTableLayoutContainer1.ResumeLayout(False)
    gcTableLayoutContainer1.Dock = DockStyle.Fill
    Me.Controls.Add(gcTableLayoutContainer1)
    gcTableLayoutContainer1.PerformLayout()
End Sub
private void CreateLuxuriantBorderForEachCell()
{
    GcTableLayoutContainer gcTableLayoutContainer1;
    TableColumn tableColumn1;
    TableColumn tableColumn2;
    TableColumn tableColumn3;
    TableColumn tableColumn4;
    TableColumn tableColumn5;
    TableColumn tableColumn6;
    TableColumn tableColumn7;
    TableColumn tableColumn8;
    TableRow tableRow1;
    TableRow tableRow2;
    TableRow tableRow3;
    TableRow tableRow4;
    TableRow tableRow5;
    TableRow tableRow6;
    TableRow tableRow7;
    TableRow tableRow8;
    Label label1;
    TextBox textBox1;
    Label label2;
    Label label3;

    Border border1 = new Border();
    Border border2 = new Border();
    Border border3 = new Border();
    Border border4 = new Border();
    Border border5 = new Border();
    Border border6 = new Border();
    Border border7 = new Border();
    Border border8 = new Border();
    Border border9 = new Border();
    Border border10 = new Border();
    Border border11 = new Border();
    Border border12 = new Border();
    Border border13 = new Border();
    Border border14 = new Border();
    Border border15 = new Border();
    Border border16 = new Border();
    Border border17 = new Border();
    Border border18 = new Border();
    Border border19 = new Border();
    Border border20 = new Border();
    Border border21 = new Border();
    Border border22 = new Border();
    Border border23 = new Border();
    Border border24 = new Border();
    Border border25 = new Border();
    Border border26 = new Border();
    Border border27 = new Border();
    Border border28 = new Border();
    RoundedBorder roundedBorder1 = new RoundedBorder();
    RoundedBorder roundedBorder2 = new RoundedBorder();
    RoundedBorder roundedBorder3 = new RoundedBorder();
    RoundedBorder roundedBorder4 = new RoundedBorder();
    Border border29 = new Border();
    ThreeDBorder threeDBorder1 = new ThreeDBorder();
    gcTableLayoutContainer1 = new GcTableLayoutContainer();
    tableColumn1 = new TableColumn();
    tableColumn2 = new TableColumn();
    tableRow1 = new TableRow();
    tableRow2 = new TableRow();
    tableColumn3 = new TableColumn();
    tableColumn4 = new TableColumn();
    tableRow3 = new TableRow();
    tableRow4 = new TableRow();
    tableColumn5 = new TableColumn();
    tableColumn6 = new TableColumn();
    tableRow5 = new TableRow();
    tableRow6 = new TableRow();
    tableColumn7 = new TableColumn();
    tableColumn8 = new TableColumn();
    tableRow7 = new TableRow();
    tableRow8 = new TableRow();
    label1 = new Label();
    textBox1 = new TextBox();
    label2 = new Label();
    label3 = new Label();
    ((System.ComponentModel.ISupportInitialize)(gcTableLayoutContainer1)).BeginInit();
    gcTableLayoutContainer1.SuspendLayout();
    // 
    // gcTableLayoutContainer1
    // 
    border1.Left = new Line(LineStyle.Thin, Color.Black);
    border1.Top = new Line(LineStyle.Thin, Color.Black);
    border2.Top = new Line(LineStyle.Thin, Color.Black);
    border3.Top = new Line(LineStyle.Thin, Color.Black);
    border4.Top = new Line(LineStyle.Thin, Color.Black);
    border5.Top = new Line(LineStyle.Thin, Color.Black);
    border6.Top = new Line(LineStyle.Thin, Color.Black);
    border7.Top = new Line(LineStyle.Thin, Color.Black);
    border8.Right = new Line(LineStyle.Thin, Color.Black);
    border8.Top = new Line(LineStyle.Thin, Color.Black);
    border9.Left = new Line(LineStyle.Thin, Color.Black);
    border10.Right = new Line(LineStyle.Thin, Color.Black);
    border11.Left = new Line(LineStyle.Thin, Color.Black);
    border12.Right = new Line(LineStyle.Thin, Color.Black);
    border13.Left = new Line(LineStyle.Thin, Color.Black);
    border14.Right = new Line(LineStyle.Thin, Color.Black);
    border15.Left = new Line(LineStyle.Thin, Color.Black);
    border16.Right = new Line(LineStyle.Thin, Color.Black);
    border17.Left = new Line(LineStyle.Thin, Color.Black);
    border18.Right = new Line(LineStyle.Thin, Color.Black);
    border19.Left = new Line(LineStyle.Thin, Color.Black);
    border20.Right = new Line(LineStyle.Thin, Color.Black);
    border21.Bottom = new Line(LineStyle.Thin, Color.Black);
    border21.Left = new Line(LineStyle.Thin, Color.Black);
    border22.Bottom = new Line(LineStyle.Thin, Color.Black);
    border23.Bottom = new Line(LineStyle.Thin, Color.Black);
    border24.Bottom = new Line(LineStyle.Thin, Color.Black);
    border25.Bottom = new Line(LineStyle.Thin, Color.Black);
    border26.Bottom = new Line(LineStyle.Thin, Color.Black);
    border27.Bottom = new Line(LineStyle.Thin, Color.Black);
    border28.Bottom = new Line(LineStyle.Thin, Color.Black);
    border28.Right = new Line(LineStyle.Thin, Color.Black);
    roundedBorder1.Bottom = new Line(LineStyle.Thin, Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(128)))), ((int)(((byte)(255))))));
    roundedBorder1.BottomLeftCornerLine = new Line(LineStyle.Thin, Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(128)))), ((int)(((byte)(255))))));
    roundedBorder1.BottomLeftCornerRadius = 0.2F;
    roundedBorder1.Left = new Line(LineStyle.Thin, Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(128)))), ((int)(((byte)(255))))));
    roundedBorder2.Bottom = new Line(LineStyle.Thin, Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(128)))), ((int)(((byte)(255))))));
    roundedBorder2.BottomRightCornerLine = new Line(LineStyle.Thin, Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(128)))), ((int)(((byte)(255))))));
    roundedBorder2.BottomRightCornerRadius = 0.2F;
    roundedBorder2.Right = new Line(LineStyle.Thin, Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(128)))), ((int)(((byte)(255))))));
    roundedBorder3.AllCornerRadius = 0.2F;
    roundedBorder3.Outline = new Line(LineStyle.Thin, Color.PaleGreen);
    roundedBorder4.Left = new Line(LineStyle.Thin, Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(128)))), ((int)(((byte)(255))))));
    roundedBorder4.Right = new Line(LineStyle.Thin, Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(128)))), ((int)(((byte)(255))))));
    roundedBorder4.Top = new Line(LineStyle.Thin, Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(128)))), ((int)(((byte)(255))))));
    roundedBorder4.TopLeftCornerLine = new Line(LineStyle.Thin, Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(128)))), ((int)(((byte)(255))))));
    roundedBorder4.TopLeftCornerRadius = 0.2F;
    roundedBorder4.TopRightCornerLine = new Line(LineStyle.Thin, Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(128)))), ((int)(((byte)(255))))));
    roundedBorder4.TopRightCornerRadius = 0.2F;
    border29.Bottom = new Line(LineStyle.Double, Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(192))))));
    border29.Left = new Line(LineStyle.Double, Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(192))))));
    border29.Right = new Line(LineStyle.Double, Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(192))))));
    border29.Top = new Line(LineStyle.Double, Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(192))))));
    threeDBorder1.DarkColor = Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(192)))), ((int)(((byte)(128)))));
    threeDBorder1.DarkDarkColor = Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))));
    threeDBorder1.LightColor = Color.FromArgb(((int)(((byte)(159)))), ((int)(((byte)(255)))), ((int)(((byte)(159)))));
    threeDBorder1.LightLightColor = Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(255)))), ((int)(((byte)(255)))));
    threeDBorder1.ThreeDEffect = ThreeDEffect.Sunken;
    gcTableLayoutContainer1.Columns.AddRange(new TableColumn[] {
    tableColumn1,
    tableColumn2,
    tableColumn3,
    tableColumn4,
    tableColumn5,
    tableColumn6,
    tableColumn7,
    tableColumn8});
    gcTableLayoutContainer1.Rows.AddRange(new TableRow[] {
    tableRow1,
    tableRow2,
    tableRow3,
    tableRow4,
    tableRow5,
    tableRow6,
    tableRow7,
    tableRow8});
    gcTableLayoutContainer1.CellInfos.AddRange(new CellInfo[] {
    new CellInfo(new CellPosition(0, 0), Color.Empty, border1, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(1, 0), Color.Empty, border2, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(2, 0), Color.Empty, border3, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(3, 0), Color.Empty, border4, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(4, 0), Color.Empty, border5, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(5, 0), Color.Empty, border6, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(6, 0), Color.Empty, border7, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(7, 0), Color.Empty, border8, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(0, 1), Color.Empty, border9, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(7, 1), Color.Empty, border10, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(0, 2), Color.Empty, border11, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(7, 2), Color.Empty, border12, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(0, 3), Color.Empty, border13, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(7, 3), Color.Empty, border14, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(0, 4), Color.Empty, border15, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(7, 4), Color.Empty, border16, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(0, 5), Color.Empty, border17, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(7, 5), Color.Empty, border18, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(0, 6), Color.Empty, border19, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(7, 6), Color.Empty, border20, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(0, 7), Color.Empty, border21, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(1, 7), Color.Empty, border22, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(2, 7), Color.Empty, border23, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(3, 7), Color.Empty, border24, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(4, 7), Color.Empty, border25, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(5, 7), Color.Empty, border26, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(6, 7), Color.Empty, border27, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(7, 7), Color.Empty, border28, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(1, 5), Color.Empty, roundedBorder1, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(2, 5), Color.Empty, roundedBorder2, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(4, 4), 3, 2, Color.Empty, roundedBorder3, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(1, 4), 2, 1, Color.Empty, roundedBorder4, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(1, 1), 2, 2, Color.Empty, border29, null, null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(4, 1), 2, 2, Color.Empty, threeDBorder1, null, null, null, ImageLayout.None, null)});
    gcTableLayoutContainer1.Controls.Add(textBox1, 4, 4);
    gcTableLayoutContainer1.Controls.Add(label1, 1, 4);
    gcTableLayoutContainer1.Controls.Add(label2, 1, 1);
    gcTableLayoutContainer1.Controls.Add(label3, 4, 1);
    gcTableLayoutContainer1.Location = new Point(12, 12);
    gcTableLayoutContainer1.Name = "gcTableLayoutContainer1";
    gcTableLayoutContainer1.Dock = DockStyle.Fill;
    gcTableLayoutContainer1.TabIndex = 0;

    // 
    // tableColumn1
    // 
    tableColumn1.SizeType = SizeType.Percent;
    tableColumn1.Width = 50F;
    // 
    // tableColumn2
    // 
    tableColumn2.SizeType = SizeType.Percent;
    tableColumn2.Width = 50F;
    // 
    // tableRow1
    // 
    tableRow1.Height = 50F;
    tableRow1.SizeType = SizeType.Percent;
    // 
    // tableRow2
    // 
    tableRow2.Height = 50F;
    tableRow2.SizeType = SizeType.Percent;
    // 
    // tableColumn3
    // 
    tableColumn3.SizeType = SizeType.Percent;
    tableColumn3.Width = 50F;
    // 
    // tableColumn4
    // 
    tableColumn4.SizeType = SizeType.Percent;
    tableColumn4.Width = 50F;
    // 
    // tableRow3
    // 
    tableRow3.Height = 50F;
    tableRow3.SizeType = SizeType.Percent;
    // 
    // tableRow4
    // 
    tableRow4.Height = 50F;
    tableRow4.SizeType = SizeType.Percent;
    // 
    // tableColumn5
    // 
    tableColumn5.SizeType = SizeType.Percent;
    tableColumn5.Width = 50F;
    // 
    // tableColumn6
    // 
    tableColumn6.SizeType = SizeType.Percent;
    tableColumn6.Width = 50F;
    // 
    // tableRow5
    // 
    tableRow5.Height = 50F;
    tableRow5.SizeType = SizeType.Percent;
    // 
    // tableRow6
    // 
    tableRow6.Height = 50F;
    tableRow6.SizeType = SizeType.Percent;
    // 
    // tableColumn7
    // 
    tableColumn7.SizeType = SizeType.Percent;
    tableColumn7.Width = 50F;
    // 
    // tableColumn8
    // 
    tableColumn8.SizeType = SizeType.Percent;
    tableColumn8.Width = 50F;
    // 
    // tableRow7
    // 
    tableRow7.Height = 50F;
    tableRow7.SizeType = SizeType.Percent;
    // 
    // tableRow8
    // 
    tableRow8.Height = 50F;
    tableRow8.SizeType = SizeType.Percent;
    // 
    // label1
    // 
    label1.AutoSize = true;
    label1.Location = new Point(56, 171);
    label1.Name = "label1";
    label1.Size = new Size(83, 12);
    label1.TabIndex = 0;
    label1.Text = "RoundedBorder";
    // 
    // textBox1
    // 
    textBox1.BorderStyle = BorderStyle.None;
    textBox1.Dock = DockStyle.Fill;
    textBox1.Location = new Point(208, 176);
    textBox1.Margin = new Padding(5);
    textBox1.Multiline = true;
    textBox1.Name = "textBox1";
    textBox1.Size = new Size(137, 71);
    textBox1.TabIndex = 1;
    textBox1.Text = "TextBox In RoundedBorder";
    // 
    // label2
    // 
    label2.AutoSize = true;
    label2.Location = new Point(56, 45);
    label2.Name = "label2";
    label2.Size = new Size(75, 12);
    label2.TabIndex = 2;
    label2.Text = "NormalBorder";
    // 
    // label3
    // 
    label3.AutoSize = true;
    label3.Location = new Point(206, 45);
    label3.Name = "label3";
    label3.Size = new Size(76, 12);
    label3.TabIndex = 3;
    label3.Text = "ThreeDBorder";

    ((System.ComponentModel.ISupportInitialize)(gcTableLayoutContainer1)).EndInit();
    gcTableLayoutContainer1.ResumeLayout(false);
    gcTableLayoutContainer1.Dock = DockStyle.Fill;
    this.Controls.Add(gcTableLayoutContainer1);
    gcTableLayoutContainer1.PerformLayout();
    this.Padding = new Padding(20);
}
Private Sub CreateLuxuriantBorderForEachCell()
    Dim gcTableLayoutContainer1 As GcTableLayoutContainer
    Dim tableColumn1 As TableColumn
    Dim tableColumn2 As TableColumn
    Dim tableColumn3 As TableColumn
    Dim tableColumn4 As TableColumn
    Dim tableColumn5 As TableColumn
    Dim tableColumn6 As TableColumn
    Dim tableColumn7 As TableColumn
    Dim tableColumn8 As TableColumn
    Dim tableRow1 As TableRow
    Dim tableRow2 As TableRow
    Dim tableRow3 As TableRow
    Dim tableRow4 As TableRow
    Dim tableRow5 As TableRow
    Dim tableRow6 As TableRow
    Dim tableRow7 As TableRow
    Dim tableRow8 As TableRow
    Dim label1 As Label
    Dim textBox1 As TextBox
    Dim label2 As Label
    Dim label3 As Label

    Dim border1 As New Border()
    Dim border2 As New Border()
    Dim border3 As New Border()
    Dim border4 As New Border()
    Dim border5 As New Border()
    Dim border6 As New Border()
    Dim border7 As New Border()
    Dim border8 As New Border()
    Dim border9 As New Border()
    Dim border10 As New Border()
    Dim border11 As New Border()
    Dim border12 As New Border()
    Dim border13 As New Border()
    Dim border14 As New Border()
    Dim border15 As New Border()
    Dim border16 As New Border()
    Dim border17 As New Border()
    Dim border18 As New Border()
    Dim border19 As New Border()
    Dim border20 As New Border()
    Dim border21 As New Border()
    Dim border22 As New Border()
    Dim border23 As New Border()
    Dim border24 As New Border()
    Dim border25 As New Border()
    Dim border26 As New Border()
    Dim border27 As New Border()
    Dim border28 As New Border()
    Dim roundedBorder1 As New RoundedBorder()
    Dim roundedBorder2 As New RoundedBorder()
    Dim roundedBorder3 As New RoundedBorder()
    Dim roundedBorder4 As New RoundedBorder()
    Dim border29 As New Border()
    Dim threeDBorder1 As New ThreeDBorder()
    gcTableLayoutContainer1 = New GcTableLayoutContainer()
    tableColumn1 = New TableColumn()
    tableColumn2 = New TableColumn()
    tableRow1 = New TableRow()
    tableRow2 = New TableRow()
    tableColumn3 = New TableColumn()
    tableColumn4 = New TableColumn()
    tableRow3 = New TableRow()
    tableRow4 = New TableRow()
    tableColumn5 = New TableColumn()
    tableColumn6 = New TableColumn()
    tableRow5 = New TableRow()
    tableRow6 = New TableRow()
    tableColumn7 = New TableColumn()
    tableColumn8 = New TableColumn()
    tableRow7 = New TableRow()
    tableRow8 = New TableRow()
    label1 = New Label()
    textBox1 = New TextBox()
    label2 = New Label()
    label3 = New Label()
    CType((gcTableLayoutContainer1), System.ComponentModel.ISupportInitialize).BeginInit()
    gcTableLayoutContainer1.SuspendLayout()
    ' 
    ' gcTableLayoutContainer1
    ' 
    border1.Left = New Line(LineStyle.Thin, Color.Black)
    border1.Top = New Line(LineStyle.Thin, Color.Black)
    border2.Top = New Line(LineStyle.Thin, Color.Black)
    border3.Top = New Line(LineStyle.Thin, Color.Black)
    border4.Top = New Line(LineStyle.Thin, Color.Black)
    border5.Top = New Line(LineStyle.Thin, Color.Black)
    border6.Top = New Line(LineStyle.Thin, Color.Black)
    border7.Top = New Line(LineStyle.Thin, Color.Black)
    border8.Right = New Line(LineStyle.Thin, Color.Black)
    border8.Top = New Line(LineStyle.Thin, Color.Black)
    border9.Left = New Line(LineStyle.Thin, Color.Black)
    border10.Right = New Line(LineStyle.Thin, Color.Black)
    border11.Left = New Line(LineStyle.Thin, Color.Black)
    border12.Right = New Line(LineStyle.Thin, Color.Black)
    border13.Left = New Line(LineStyle.Thin, Color.Black)
    border14.Right = New Line(LineStyle.Thin, Color.Black)
    border15.Left = New Line(LineStyle.Thin, Color.Black)
    border16.Right = New Line(LineStyle.Thin, Color.Black)
    border17.Left = New Line(LineStyle.Thin, Color.Black)
    border18.Right = New Line(LineStyle.Thin, Color.Black)
    border19.Left = New Line(LineStyle.Thin, Color.Black)
    border20.Right = New Line(LineStyle.Thin, Color.Black)
    border21.Bottom = New Line(LineStyle.Thin, Color.Black)
    border21.Left = New Line(LineStyle.Thin, Color.Black)
    border22.Bottom = New Line(LineStyle.Thin, Color.Black)
    border23.Bottom = New Line(LineStyle.Thin, Color.Black)
    border24.Bottom = New Line(LineStyle.Thin, Color.Black)
    border25.Bottom = New Line(LineStyle.Thin, Color.Black)
    border26.Bottom = New Line(LineStyle.Thin, Color.Black)
    border27.Bottom = New Line(LineStyle.Thin, Color.Black)
    border28.Bottom = New Line(LineStyle.Thin, Color.Black)
    border28.Right = New Line(LineStyle.Thin, Color.Black)
    roundedBorder1.Bottom = New Line(LineStyle.Thin, Color.FromArgb(CType(CType((128), Byte), Integer), CType(CType((128), Byte), Integer), CType(CType((255), Byte), Integer)))
    roundedBorder1.BottomLeftCornerLine = New Line(LineStyle.Thin, Color.FromArgb(CType(CType((128), Byte), Integer), CType(CType((128), Byte), Integer), CType(CType((255), Byte), Integer)))
    roundedBorder1.BottomLeftCornerRadius = 0.2F
    roundedBorder1.Left = New Line(LineStyle.Thin, Color.FromArgb(CType(CType((128), Byte), Integer), CType(CType((128), Byte), Integer), CType(CType((255), Byte), Integer)))
    roundedBorder2.Bottom = New Line(LineStyle.Thin, Color.FromArgb(CType(CType((128), Byte), Integer), CType(CType((128), Byte), Integer), CType(CType((255), Byte), Integer)))
    roundedBorder2.BottomRightCornerLine = New Line(LineStyle.Thin, Color.FromArgb(CType(CType((128), Byte), Integer), CType(CType((128), Byte), Integer), CType(CType((255), Byte), Integer)))
    roundedBorder2.BottomRightCornerRadius = 0.2F
    roundedBorder2.Right = New Line(LineStyle.Thin, Color.FromArgb(CType(CType((128), Byte), Integer), CType(CType((128), Byte), Integer), CType(CType((255), Byte), Integer)))
    roundedBorder3.AllCornerRadius = 0.2F
    roundedBorder3.Outline = New Line(LineStyle.Thin, Color.PaleGreen)
    roundedBorder4.Left = New Line(LineStyle.Thin, Color.FromArgb(CType(CType((128), Byte), Integer), CType(CType((128), Byte), Integer), CType(CType((255), Byte), Integer)))
    roundedBorder4.Right = New Line(LineStyle.Thin, Color.FromArgb(CType(CType((128), Byte), Integer), CType(CType((128), Byte), Integer), CType(CType((255), Byte), Integer)))
    roundedBorder4.Top = New Line(LineStyle.Thin, Color.FromArgb(CType(CType((128), Byte), Integer), CType(CType((128), Byte), Integer), CType(CType((255), Byte), Integer)))
    roundedBorder4.TopLeftCornerLine = New Line(LineStyle.Thin, Color.FromArgb(CType(CType((128), Byte), Integer), CType(CType((128), Byte), Integer), CType(CType((255), Byte), Integer)))
    roundedBorder4.TopLeftCornerRadius = 0.2F
    roundedBorder4.TopRightCornerLine = New Line(LineStyle.Thin, Color.FromArgb(CType(CType((128), Byte), Integer), CType(CType((128), Byte), Integer), CType(CType((255), Byte), Integer)))
    roundedBorder4.TopRightCornerRadius = 0.2F
    border29.Bottom = New Line(LineStyle.[Double], Color.FromArgb(CType(CType((192), Byte), Integer), CType(CType((255), Byte), Integer), CType(CType((192), Byte), Integer)))
    border29.Left = New Line(LineStyle.[Double], Color.FromArgb(CType(CType((192), Byte), Integer), CType(CType((255), Byte), Integer), CType(CType((192), Byte), Integer)))
    border29.Right = New Line(LineStyle.[Double], Color.FromArgb(CType(CType((192), Byte), Integer), CType(CType((255), Byte), Integer), CType(CType((192), Byte), Integer)))
    border29.Top = New Line(LineStyle.[Double], Color.FromArgb(CType(CType((192), Byte), Integer), CType(CType((255), Byte), Integer), CType(CType((192), Byte), Integer)))
    threeDBorder1.DarkColor = Color.FromArgb(CType(CType((255), Byte), Integer), CType(CType((192), Byte), Integer), CType(CType((128), Byte), Integer))
    threeDBorder1.DarkDarkColor = Color.FromArgb(CType(CType((0), Byte), Integer), CType(CType((0), Byte), Integer), CType(CType((0), Byte), Integer))
    threeDBorder1.LightColor = Color.FromArgb(CType(CType((159), Byte), Integer), CType(CType((255), Byte), Integer), CType(CType((159), Byte), Integer))
    threeDBorder1.LightLightColor = Color.FromArgb(CType(CType((128), Byte), Integer), CType(CType((255), Byte), Integer), CType(CType((255), Byte), Integer))
    threeDBorder1.ThreeDEffect = ThreeDEffect.Sunken
    gcTableLayoutContainer1.Columns.AddRange(New TableColumn() {tableColumn1, tableColumn2, tableColumn3, tableColumn4, tableColumn5, tableColumn6, _
     tableColumn7, tableColumn8})
    gcTableLayoutContainer1.Rows.AddRange(New TableRow() {tableRow1, tableRow2, tableRow3, tableRow4, tableRow5, tableRow6, _
     tableRow7, tableRow8})
    gcTableLayoutContainer1.CellInfos.AddRange(New CellInfo() {New CellInfo(New CellPosition(0, 0), Color.Empty, border1, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(1, 0), Color.Empty, border2, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(2, 0), Color.Empty, border3, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(3, 0), Color.Empty, border4, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(4, 0), Color.Empty, border5, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(5, 0), Color.Empty, border6, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), _
     New CellInfo(New CellPosition(6, 0), Color.Empty, border7, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(7, 0), Color.Empty, border8, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(0, 1), Color.Empty, border9, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(7, 1), Color.Empty, border10, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(0, 2), Color.Empty, border11, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(7, 2), Color.Empty, border12, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), _
     New CellInfo(New CellPosition(0, 3), Color.Empty, border13, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(7, 3), Color.Empty, border14, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(0, 4), Color.Empty, border15, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(7, 4), Color.Empty, border16, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(0, 5), Color.Empty, border17, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(7, 5), Color.Empty, border18, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), _
     New CellInfo(New CellPosition(0, 6), Color.Empty, border19, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(7, 6), Color.Empty, border20, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(0, 7), Color.Empty, border21, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(1, 7), Color.Empty, border22, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(2, 7), Color.Empty, border23, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(3, 7), Color.Empty, border24, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), _
     New CellInfo(New CellPosition(4, 7), Color.Empty, border25, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(5, 7), Color.Empty, border26, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(6, 7), Color.Empty, border27, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(7, 7), Color.Empty, border28, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(1, 5), Color.Empty, roundedBorder1, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(2, 5), Color.Empty, roundedBorder2, Nothing, Nothing, Nothing, ImageLayout.None, Nothing), _
     New CellInfo(New CellPosition(4, 4), 3, 2, Color.Empty, roundedBorder3, Nothing, _
     Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(1, 4), 2, 1, Color.Empty, roundedBorder4, Nothing, _
     Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(1, 1), 2, 2, Color.Empty, border29, Nothing, _
     Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(4, 1), 2, 2, Color.Empty, threeDBorder1, Nothing, _
     Nothing, Nothing, ImageLayout.None, Nothing)})
    gcTableLayoutContainer1.Controls.Add(textBox1, 4, 4)
    gcTableLayoutContainer1.Controls.Add(label1, 1, 4)
    gcTableLayoutContainer1.Controls.Add(label2, 1, 1)
    gcTableLayoutContainer1.Controls.Add(label3, 4, 1)
    gcTableLayoutContainer1.Location = New Point(12, 12)
    gcTableLayoutContainer1.Name = "gcTableLayoutContainer1"
    gcTableLayoutContainer1.Dock = DockStyle.Fill
    gcTableLayoutContainer1.TabIndex = 0

    ' 
    ' tableColumn1
    ' 
    tableColumn1.SizeType = SizeType.Percent
    tableColumn1.Width = 50.0F
    ' 
    ' tableColumn2
    ' 
    tableColumn2.SizeType = SizeType.Percent
    tableColumn2.Width = 50.0F
    ' 
    ' tableRow1
    ' 
    tableRow1.Height = 50.0F
    tableRow1.SizeType = SizeType.Percent
    ' 
    ' tableRow2
    ' 
    tableRow2.Height = 50.0F
    tableRow2.SizeType = SizeType.Percent
    ' 
    ' tableColumn3
    ' 
    tableColumn3.SizeType = SizeType.Percent
    tableColumn3.Width = 50.0F
    ' 
    ' tableColumn4
    ' 
    tableColumn4.SizeType = SizeType.Percent
    tableColumn4.Width = 50.0F
    ' 
    ' tableRow3
    ' 
    tableRow3.Height = 50.0F
    tableRow3.SizeType = SizeType.Percent
    ' 
    ' tableRow4
    ' 
    tableRow4.Height = 50.0F
    tableRow4.SizeType = SizeType.Percent
    ' 
    ' tableColumn5
    ' 
    tableColumn5.SizeType = SizeType.Percent
    tableColumn5.Width = 50.0F
    ' 
    ' tableColumn6
    ' 
    tableColumn6.SizeType = SizeType.Percent
    tableColumn6.Width = 50.0F
    ' 
    ' tableRow5
    ' 
    tableRow5.Height = 50.0F
    tableRow5.SizeType = SizeType.Percent
    ' 
    ' tableRow6
    ' 
    tableRow6.Height = 50.0F
    tableRow6.SizeType = SizeType.Percent
    ' 
    ' tableColumn7
    ' 
    tableColumn7.SizeType = SizeType.Percent
    tableColumn7.Width = 50.0F
    ' 
    ' tableColumn8
    ' 
    tableColumn8.SizeType = SizeType.Percent
    tableColumn8.Width = 50.0F
    ' 
    ' tableRow7
    ' 
    tableRow7.Height = 50.0F
    tableRow7.SizeType = SizeType.Percent
    ' 
    ' tableRow8
    ' 
    tableRow8.Height = 50.0F
    tableRow8.SizeType = SizeType.Percent
    ' 
    ' label1
    ' 
    label1.AutoSize = True
    label1.Location = New Point(56, 171)
    label1.Name = "label1"
    label1.Size = New Size(83, 12)
    label1.TabIndex = 0
    label1.Text = "RoundedBorder"
    ' 
    ' textBox1
    ' 
    textBox1.BorderStyle = BorderStyle.None
    textBox1.Dock = DockStyle.Fill
    textBox1.Location = New Point(208, 176)
    textBox1.Margin = New Padding(5)
    textBox1.Multiline = True
    textBox1.Name = "textBox1"
    textBox1.Size = New Size(137, 71)
    textBox1.TabIndex = 1
    textBox1.Text = "TextBox In RoundedBorder"
    ' 
    ' label2
    ' 
    label2.AutoSize = True
    label2.Location = New Point(56, 45)
    label2.Name = "label2"
    label2.Size = New Size(75, 12)
    label2.TabIndex = 2
    label2.Text = "NormalBorder"
    ' 
    ' label3
    ' 
    label3.AutoSize = True
    label3.Location = New Point(206, 45)
    label3.Name = "label3"
    label3.Size = New Size(76, 12)
    label3.TabIndex = 3
    label3.Text = "ThreeDBorder"

    CType((gcTableLayoutContainer1), System.ComponentModel.ISupportInitialize).EndInit()
    gcTableLayoutContainer1.ResumeLayout(False)
    gcTableLayoutContainer1.Dock = DockStyle.Fill
    Me.Controls.Add(gcTableLayoutContainer1)
    gcTableLayoutContainer1.PerformLayout()
    Me.Padding = New Padding(20)
End Sub
private void CreateLuxuriantBackgroundForEachCell()
{
    GcTableLayoutContainer gcTableLayoutContainer1;
    TableColumn tableColumn1;
    TableColumn tableColumn2;
    TableRow tableRow1;
    TableRow tableRow2;
    Border border1 = new Border();
    Border border2 = new Border();
    Border border3 = new Border();
    Border border4 = new Border();
    gcTableLayoutContainer1 = new GcTableLayoutContainer();
    tableColumn1 = new TableColumn();
    tableColumn2 = new TableColumn();
    tableRow1 = new TableRow();
    tableRow2 = new TableRow();
    ((System.ComponentModel.ISupportInitialize)(gcTableLayoutContainer1)).BeginInit();
    // 
    // gcTableLayoutContainer1
    // 
    border1.Bottom = new Line(LineStyle.Thin, Color.Black);
    border1.Left = new Line(LineStyle.Thin, Color.Black);
    border1.Right = new Line(LineStyle.Thin, Color.Black);
    border1.Top = new Line(LineStyle.Thin, Color.Black);
    border2.Bottom = new Line(LineStyle.Thin, Color.Black);
    border2.Left = new Line(LineStyle.Thin, Color.Black);
    border2.Right = new Line(LineStyle.Thin, Color.Black);
    border2.Top = new Line(LineStyle.Thin, Color.Black);
    border3.Bottom = new Line(LineStyle.Thin, Color.Black);
    border3.Left = new Line(LineStyle.Thin, Color.Black);
    border3.Right = new Line(LineStyle.Thin, Color.Black);
    border3.Top = new Line(LineStyle.Thin, Color.Black);
    border4.Bottom = new Line(LineStyle.Thin, Color.Black);
    border4.Left = new Line(LineStyle.Thin, Color.Black);
    border4.Right = new Line(LineStyle.Thin, Color.Black);
    border4.Top = new Line(LineStyle.Thin, Color.Black);
    gcTableLayoutContainer1.Columns.AddRange(new TableColumn[] {
    tableColumn1,
    tableColumn2});
    gcTableLayoutContainer1.Rows.AddRange(new TableRow[] {
    tableRow1,
    tableRow2});
    gcTableLayoutContainer1.CellInfos.AddRange(new CellInfo[] {
    new CellInfo(new CellPosition(0, 0), Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128))))), border1, new PatternEffect(PatternStyle.Horizontal, Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(255)))), ((int)(((byte)(255)))))), null, null, ImageLayout.None, null),
    new CellInfo(new CellPosition(1, 0), Color.Empty, border2, null, new GradientEffect(GradientStyle.Vertical, GradientDirection.Side, Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(255)))), ((int)(((byte)(128))))), Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(128)))), ((int)(((byte)(255)))))), null, ImageLayout.None, null),
    new CellInfo(new CellPosition(0, 1), Color.Empty, border3, null, new GradientEffect(GradientStyle.Rectangular, GradientDirection.NotSet, Color.FromArgb(((int)(((byte)(94)))), ((int)(((byte)(158)))), ((int)(((byte)(255))))), Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(255)))))), null, ImageLayout.None, null),
    new CellInfo(new CellPosition(1, 1), Color.Empty, border4, null, new GradientEffect(GradientStyle.Elliptical, GradientDirection.NotSet, Color.FromArgb(((int)(((byte)(132)))), ((int)(((byte)(136)))), ((int)(((byte)(196))))), Color.FromArgb(((int)(((byte)(212)))), ((int)(((byte)(222)))), ((int)(((byte)(255)))))), null, ImageLayout.None, null)});
    gcTableLayoutContainer1.Location = new Point(9, 23);
    gcTableLayoutContainer1.Name = "gcTableLayoutContainer1";
    gcTableLayoutContainer1.Size = new Size(369, 250);
    gcTableLayoutContainer1.TabIndex = 0;
    // 
    // tableColumn1
    // 
    tableColumn1.SizeType = SizeType.Percent;
    tableColumn1.Width = 50F;
    // 
    // tableColumn2
    // 
    tableColumn2.SizeType = SizeType.Percent;
    tableColumn2.Width = 50F;
    // 
    // tableRow1
    // 
    tableRow1.Height = 50F;
    tableRow1.SizeType = SizeType.Percent;
    // 
    // tableRow2
    // 
    tableRow2.Height = 50F;
    tableRow2.SizeType = SizeType.Percent;

    ((System.ComponentModel.ISupportInitialize)(gcTableLayoutContainer1)).EndInit();
    gcTableLayoutContainer1.ResumeLayout(false);
    gcTableLayoutContainer1.Dock = DockStyle.Fill;
    this.Controls.Add(gcTableLayoutContainer1);
    gcTableLayoutContainer1.PerformLayout();
    this.Padding = new Padding(20);
}
Private Sub CreateLuxuriantBackgroundForEachCell()
    Dim gcTableLayoutContainer1 As GcTableLayoutContainer
    Dim tableColumn1 As TableColumn
    Dim tableColumn2 As TableColumn
    Dim tableRow1 As TableRow
    Dim tableRow2 As TableRow
    Dim border1 As New Border()
    Dim border2 As New Border()
    Dim border3 As New Border()
    Dim border4 As New Border()
    gcTableLayoutContainer1 = New GcTableLayoutContainer()
    tableColumn1 = New TableColumn()
    tableColumn2 = New TableColumn()
    tableRow1 = New TableRow()
    tableRow2 = New TableRow()
    CType((gcTableLayoutContainer1), System.ComponentModel.ISupportInitialize).BeginInit()
    ' 
    ' gcTableLayoutContainer1
    ' 
    border1.Bottom = New Line(LineStyle.Thin, Color.Black)
    border1.Left = New Line(LineStyle.Thin, Color.Black)
    border1.Right = New Line(LineStyle.Thin, Color.Black)
    border1.Top = New Line(LineStyle.Thin, Color.Black)
    border2.Bottom = New Line(LineStyle.Thin, Color.Black)
    border2.Left = New Line(LineStyle.Thin, Color.Black)
    border2.Right = New Line(LineStyle.Thin, Color.Black)
    border2.Top = New Line(LineStyle.Thin, Color.Black)
    border3.Bottom = New Line(LineStyle.Thin, Color.Black)
    border3.Left = New Line(LineStyle.Thin, Color.Black)
    border3.Right = New Line(LineStyle.Thin, Color.Black)
    border3.Top = New Line(LineStyle.Thin, Color.Black)
    border4.Bottom = New Line(LineStyle.Thin, Color.Black)
    border4.Left = New Line(LineStyle.Thin, Color.Black)
    border4.Right = New Line(LineStyle.Thin, Color.Black)
    border4.Top = New Line(LineStyle.Thin, Color.Black)
    gcTableLayoutContainer1.Columns.AddRange(New TableColumn() {tableColumn1, tableColumn2})
    gcTableLayoutContainer1.Rows.AddRange(New TableRow() {tableRow1, tableRow2})
    gcTableLayoutContainer1.CellInfos.AddRange(New CellInfo() {New CellInfo(New CellPosition(0, 0), Color.FromArgb(CType(CType((255), Byte), Integer), CType(CType((255), Byte), Integer), CType(CType((128), Byte), Integer)), border1, New PatternEffect(PatternStyle.Horizontal, Color.FromArgb(CType(CType((128), Byte), Integer), CType(CType((255), Byte), Integer), CType(CType((255), Byte), Integer))), Nothing, Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(1, 0), Color.Empty, border2, Nothing, New GradientEffect(GradientStyle.Vertical, GradientDirection.Side, Color.FromArgb(CType(CType((128), Byte), Integer), CType(CType((255), Byte), Integer), CType(CType((128), Byte), Integer)), Color.FromArgb(CType(CType((128), Byte), Integer), CType(CType((128), Byte), Integer), CType(CType((255), Byte), Integer))), Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(0, 1), Color.Empty, border3, Nothing, New GradientEffect(GradientStyle.Rectangular, GradientDirection.NotSet, Color.FromArgb(CType(CType((94), Byte), Integer), CType(CType((158), Byte), Integer), CType(CType((255), Byte), Integer)), Color.FromArgb(CType(CType((255), Byte), Integer), CType(CType((255), Byte), Integer), CType(CType((255), Byte), Integer))), Nothing, ImageLayout.None, Nothing), New CellInfo(New CellPosition(1, 1), Color.Empty, border4, Nothing, New GradientEffect(GradientStyle.Elliptical, GradientDirection.NotSet, Color.FromArgb(CType(CType((132), Byte), Integer), CType(CType((136), Byte), Integer), CType(CType((196), Byte), Integer)), Color.FromArgb(CType(CType((212), Byte), Integer), CType(CType((222), Byte), Integer), CType(CType((255), Byte), Integer))), Nothing, ImageLayout.None, Nothing)})
    gcTableLayoutContainer1.Location = New Point(9, 23)
    gcTableLayoutContainer1.Name = "gcTableLayoutContainer1"
    gcTableLayoutContainer1.Size = New Size(369, 250)
    gcTableLayoutContainer1.TabIndex = 0
    ' 
    ' tableColumn1
    ' 
    tableColumn1.SizeType = SizeType.Percent
    tableColumn1.Width = 50.0F
    ' 
    ' tableColumn2
    ' 
    tableColumn2.SizeType = SizeType.Percent
    tableColumn2.Width = 50.0F
    ' 
    ' tableRow1
    ' 
    tableRow1.Height = 50.0F
    tableRow1.SizeType = SizeType.Percent
    ' 
    ' tableRow2
    ' 
    tableRow2.Height = 50.0F
    tableRow2.SizeType = SizeType.Percent

    CType((gcTableLayoutContainer1), System.ComponentModel.ISupportInitialize).EndInit()
    gcTableLayoutContainer1.ResumeLayout(False)
    gcTableLayoutContainer1.Dock = DockStyle.Fill
    Me.Controls.Add(gcTableLayoutContainer1)
    gcTableLayoutContainer1.PerformLayout()
    Me.Padding = New Padding(20)
End Sub
継承階層

System.Object
   System.MarshalByRefObject
      System.ComponentModel.Component
         System.Windows.Forms.Control
            System.Windows.Forms.ScrollableControl
               System.Windows.Forms.Panel
                  GrapeCity.Win.Containers.GcTableLayoutContainer

プラットフォーム

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

参照

GcTableLayoutContainer メンバ
GrapeCity.Win.Containers 名前空間

Send Feedback