Font.FromLogFont Font.FromLogFont Font.FromLogFont Font.FromLogFont Method

定義

從指定的 GDI 邏輯字型 (LOGFONT) 結構建立 FontCreates a Font from the specified GDI logical font (LOGFONT) structure.

多載

FromLogFont(Object, IntPtr) FromLogFont(Object, IntPtr) FromLogFont(Object, IntPtr) FromLogFont(Object, IntPtr)

從指定的 GDI 邏輯字型 (LOGFONT) 結構建立 FontCreates a Font from the specified GDI logical font (LOGFONT) structure.

FromLogFont(Object) FromLogFont(Object) FromLogFont(Object) FromLogFont(Object)

從指定的 GDI 邏輯字型 (LOGFONT) 結構建立 FontCreates a Font from the specified GDI logical font (LOGFONT) structure.

FromLogFont(Object, IntPtr) FromLogFont(Object, IntPtr) FromLogFont(Object, IntPtr) FromLogFont(Object, IntPtr)

從指定的 GDI 邏輯字型 (LOGFONT) 結構建立 FontCreates a Font from the specified GDI logical font (LOGFONT) structure.

public:
 static System::Drawing::Font ^ FromLogFont(System::Object ^ lf, IntPtr hdc);
public static System.Drawing.Font FromLogFont (object lf, IntPtr hdc);
static member FromLogFont : obj * nativeint -> System.Drawing.Font
Public Shared Function FromLogFont (lf As Object, hdc As IntPtr) As Font

參數

lf
Object Object Object Object

Object,表示從其中建立 FontGDIGDI LOGFONT 結構。An Object that represents the GDIGDI LOGFONT structure from which to create the Font.

hdc
IntPtr IntPtr IntPtr IntPtr

含有 lf 結構相關額外資訊的裝置內容控制代碼。A handle to a device context that contains additional information about the lf structure.

傳回

這個方法建立的 FontThe Font that this method creates.

例外狀況

字型不是 TrueType 字型。The font is not a TrueType font.

備註

GDIGDI (或邏輯字型)是一個結構,其中包含14個描述LOGFONT特定字型的屬性。A GDIGDI LOGFONT, or logical font, is a structure that contains 14 properties that describe a particular font.

安全性

SecurityPermission
用於存取未受管理的程式碼。for access to unmanaged code. 相關列舉:UnmanagedCodeRelated enumeration: UnmanagedCode

FromLogFont(Object) FromLogFont(Object) FromLogFont(Object) FromLogFont(Object)

從指定的 GDI 邏輯字型 (LOGFONT) 結構建立 FontCreates a Font from the specified GDI logical font (LOGFONT) structure.

public:
 static System::Drawing::Font ^ FromLogFont(System::Object ^ lf);
public static System.Drawing.Font FromLogFont (object lf);
static member FromLogFont : obj -> System.Drawing.Font
Public Shared Function FromLogFont (lf As Object) As Font

參數

lf
Object Object Object Object

Object,表示從其中建立 FontGDIGDI LOGFONT 結構。An Object that represents the GDIGDI LOGFONT structure from which to create the Font.

傳回

這個方法建立的 FontThe Font that this method creates.

備註

GDIGDI (或邏輯字型)是一個結構,其中包含14個描述LOGFONT特定字型的屬性。A GDIGDI LOGFONT, or logical font, is a structure that contains 14 properties that describe a particular font.

安全性

SecurityPermission
用於存取未受管理的程式碼。for access to unmanaged code. 相關列舉:UnmanagedCodeRelated enumeration: UnmanagedCode

適用於