setAttributes(_:)
Sets the style attributes for the candidates window.
Declaration
func setAttributes(_ attributes: [AnyHashable : Any]!)Parameters
- attributes:
A dictionary that contains keys and values for the styles to use. You can supply the keys and values listed in the following table:
Key
Value
NSFontAttributeName
An
NSFontobject. Setting the font attribute sets the font that is used to draw Candidates. It does not effect the selection keys which are always drawn in the same font. Note that to set the font size you should use this key/value pair.IMKCandidatesOpacityAttributeName
An
NSNumberobject that represents a floating-point value between0.0(transparent) and1.0(completely opaque. The default opacity is1.0.NSForegroundColorAttributeName
An
NSColorobject to use for the candidate text color. The default color is black.NSBackgroundColorDocumentAttribute
An
NSColorobject to use for the background color behind the candidate text.