英語で読む

次の方法で共有


TabAlignment 列挙型

定義

タブ コントロールのタブの位置を指定します。

C#
public enum TabAlignment
継承
TabAlignment

フィールド

Bottom 1

タブはコントロールの下部に配置されています。

Left 2

タブはコントロールの左端に配置されています。

Right 3

タブはコントロールの右端に配置されています。

Top 0

タブはコントロールの上部に配置されています。

次のコード例では、and プロパティとTabControl.Appearance列挙型のTabControl.Alignment使用方法をTabAlignmentTabAppearance示します。 この例を実行するには、TabControl1 という名前のフォームに次のコードを TabControl 貼り付けます。 フォームのコンストラクターまたは Load メソッドで ChangeTheLookOfTheTabControl メソッドを呼び出します。

C#
private void ChangeTheLookOfTheTabControl()
{

    // Set the size and location of the TabControl.
    this.TabControl1.Location = new System.Drawing.Point(20, 20);
    TabControl1.Size = new System.Drawing.Size(250, 250);

    // Align the tabs along the bottom of the control.
    TabControl1.Alignment = TabAlignment.Bottom;

    // Change the tabs to flat buttons.
    TabControl1.Appearance = TabAppearance.FlatButtons;
}

注釈

この列挙型は、次のような TabControl.Alignmentメンバーによって使用されます。

適用対象

製品 バージョン
.NET Framework 1.1, 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8
Windows Desktop 3.0, 3.1, 5, 6, 7

こちらもご覧ください