convert(_:)
Converts the given font according to the object that initiated a font change, typically the Font panel or Font menu.
Declaration
func convert(_ fontObj: NSFont) -> NSFontParameters
- fontObj:
The font to convert.
Return Value
The converted font, or aFont itself if the conversion isn’t possible.
Discussion
This method is invoked in response to an action message such as addFontTrait(_:) or modifyFontViaPanel(_:). These initiating methods cause the font manager to query the sender for the action to take and the traits to change. See Converting Fonts Manually for more information.