These font attributes are defined by NSFont
.
SDK
- macOS 10.13+
Framework
- App
Kit
Declaration
struct AttributeName
Overview
You can retrieve the values for these attributes using object(for
.
These font attributes are defined by NSFont
.
SDK
Framework
struct AttributeName
You can retrieve the values for these attributes using object(for
.
static let family: NSFont Descriptor .Attribute Name
An optional NSString
object that specifies the font family.
static let name: NSFont Descriptor .Attribute Name
An optional NSString
object that specifies the font name.
static let face: NSFont Descriptor .Attribute Name
An optional NSString
object that specifies the font face.
static let size: NSFont Descriptor .Attribute Name
An optional NSNumber
object, containing a float value, that specifies the font size.
static let visible Name: NSFont Descriptor .Attribute Name
An optional NSString
object that specifies the font’s visible name.
static let matrix: NSFont Descriptor .Attribute Name
An NSAffine
instance that specifies the font’s transformation matrix.
static let variation: NSFont Descriptor .Attribute Name
An NSDictionary
instance that describes the font’s variation axis.
static let character Set: NSFont Descriptor .Attribute Name
An NSCharacter
instance that represents the set of Unicode characters covered by the font.
static let cascade List: NSFont Descriptor .Attribute Name
An NSArray
instance—each member of the array is a sub-descriptor.
static let traits: NSFont Descriptor .Attribute Name
An NSDictionary
instance fully describing font traits.
static let fixed Advance: NSFont Descriptor .Attribute Name
An NSNumber
instance containing a float value that overrides the glyph advancement specified by the font.
var font Attributes: [NSFont Descriptor .Attribute Name : Any]
The receiver’s dictionary of attributes.
func object(for Key: NSFont Descriptor .Attribute Name) -> Any?
Returns the font attribute specified by the given key.
var matrix: Affine Transform?
The current transform matrix of the receiver.
var point Size: CGFloat
The point size of the receiver.
var postscript Name: String?
The PostScript name of the receiver.