AxHost.GetIFontFromFont(Font) AxHost.GetIFontFromFont(Font) AxHost.GetIFontFromFont(Font) Method

定义

返回从指定的 Font 对象创建的 OLE IFont 对象。Returns an OLE IFont object created from the specified Font object.

protected:
 static System::Object ^ GetIFontFromFont(System::Drawing::Font ^ font);
protected static object GetIFontFromFont (System.Drawing.Font font);
static member GetIFontFromFont : System.Drawing.Font -> obj

参数

font
Font Font Font

要从其创建 IFont 对象的字体。The font to create an IFont object from.

返回

从指定字体创建的 IFont 对象;如果 fontnull,则为 null;或无法创建 IFont 对象。The IFont object created from the specified font, or null if font is null or the IFont could not be created.

异常

Unit 属性值不为 PointThe Unit property value is not Point.

适用于

另请参阅