Scaled Metric Surprises on iOS & iPadOS
Read OriginalThis technical article details how UIKit's UIFontMetrics.scaledValue(for:) and SwiftUI's @ScaledMetric property wrapper do not scale values proportionally to the default system font sizes for a given text style (e.g., .body). It demonstrates the divergence with code examples and recommends directly using a UIFont's pointSize for exact proportional scaling with dynamic type.
Comments
No comments yet
Be the first to share your thoughts!
Browser Extension
Get instant access to AllDevBlogs from your browser