Post

Replies

Boosts

Views

Activity

Reply to How to resize VisionOS window proportionally?
You can access the UIWindowScene call requestGeometryUpdate on it, like so: (on some view) .onAppear() { guard let windowScene = UIApplication.shared.connectedScenes.first as? UIWindowScene else { return } let geometryRequest = UIWindowScene.GeometryPreferences.Vision( // addition parameters: size, max size ... resizingRestrictions: .uniform // maintain aspect ratio when resizing ) windowScene.requestGeometryUpdate(geometryRequest) }
Jan ’24