MonobjcMonobjc Documented Class Library
ConvertFontToFace Method (aFont, typeface)
NamespacesMonobjc.AppKitNSFontManagerConvertFontToFace(NSFont, NSString)

Returns a font whose traits are as similar as possible to those of the given font except for the typeface, which is changed to the given typeface.

Original signature is '- (NSFont *)convertFont:(NSFont *)aFont toFace:(NSString *)typeface'

Available in Mac OS X v10.0 and later.

Declaration Syntax
C#Visual BasicVisual C++
public virtual NSFont ConvertFontToFace(
	NSFont aFont,
	NSString typeface
)
Public Overridable Function ConvertFontToFace ( _
	aFont As NSFont, _
	typeface As NSString _
) As NSFont
public:
virtual NSFont^ ConvertFontToFace(
	NSFont^ aFont, 
	NSString^ typeface
)
Parameters
aFont (NSFont)
The font whose traits are matched.
typeface (NSString)
The new typeface; a fully specified family-face name, such as Helvetica-BoldOblique or Times-Roman.
Return Value
A font with matching traits and the given typeface, or aFont if it can’t be converted.
Version Information
  • Available in Monobjc Bridge: 10.6 (For Mac OS X 10.6 and later), 10.5 (For Mac OS X 10.5 and later)

Assembly: Monobjc.AppKit (Module: Monobjc.AppKit)