Variable font, styles, metrics and colors
This release is a major overhaul of SRG Appearance.
Variable font
The SRG SSR font is now variable with support for arbitrary weights. Both the text and display fonts are provided.
Styles
SRG Appearance now provides several built-in styles which corresponds to fixed sizes, weights and scaling behaviors, defined both for iOS and tvOS. Your designs can benefit from using these standard styles across platforms.
If your application does not want to use the standard styles we provide SRG Appearance still provides an API with which you can define your own styles.
Remark
Standard styles support XS, S, M, L, XL and XXL content sizes, but not accessibility sizes. Accessibility sizes are namely tricky to support from a layout perspective. If your application still wants to support such sizes you should define your own styles, which can support arbitrary content sizes.
Metrics
SRG Appearance provides UIFontMetrics
matching its styles (as well as the @SRGScaledMetric
property wrapper for SwiftUI) which allows you to scale scalar values depending on content size settings.
Colors
Several gray colors have been added.
Swift and SwiftUI support
SRG Appearance now provides improved APIs for Swift and SwiftUI. Swift code must link against SRGAppearanceSwift
to use these APIs.
Minimum deployment target
The minimum deployment target has been bumped to iOS 12.