An object that manages standard appearance attributes for UI elements in an app.
- macOS 10.9+
Appearance information is stored in files. An app can contain multiple appearance files and—because
NSAppearance conforms to
NSCoding—you can use Interface Builder to assign UI elements to an appearance.
If the art for a specific view can’t be found, AppKit searches for the art in the appearances of the view’s ancestors. A
nil appearance means that a view uses the default Aqua appearance; a non-
nil appearance means that the view uses an ancestor’s appearance.
When AppKit draws a control, it automatically sets the current appearance on the current thread to the control’s appearance. The current appearance can influence the actual drawing path and the return values you get when you access system fonts and colors. The current appearance also affects the appearance of text and images, such as the text and template images that can be displayed in a toolbar.