Share via


DataGrid.CaptionFont 屬性

定義

取得或設定方格標題的字型。

public:
 property System::Drawing::Font ^ CaptionFont { System::Drawing::Font ^ get(); void set(System::Drawing::Font ^ value); };
public System.Drawing.Font CaptionFont { get; set; }
member this.CaptionFont : System.Drawing.Font with get, set
Public Property CaptionFont As Font

屬性值

Font

Font,代表標題字型。

範例

下列程式碼範例會使用 Font 物件來設定標題的字型。

Private Sub SetCaptionFont(ByRef myGrid As DataGrid, newFont As System.Drawing.Font)
    myGrid.CaptionFont = newFont
 End Sub

備註

Font封裝Windows字型,並提供操作該字型的方法。

適用於

另請參閱