Not able to get SwiftUI Form content size. I am trying to get full size of a SwiftUI Form which has more content than screen size, that makes it scrollable. Using GeometryReader only gives the screen size (device height) rather than full content height. My next milestone would be to take a snapshot of the entire Form and convert it to UIImage or PDF.
Asked
Active
Viewed 104 times
0
-
You need to create an image, recontructing the form, for youself. – El Tomato Jul 02 '21 at 08:22
-
I didn't get you, in simple words I have scrollable Form build from SwiftUI Form component and I want to take the snapshot of the entire content both on screen, off screen – gagan sharma Jul 02 '21 at 08:28
-
Okay... I know what I have read. And? – El Tomato Jul 02 '21 at 08:34
-
And? -> please elaborate your comment/ solution .. – gagan sharma Jul 02 '21 at 08:44
-
This has been answered here: https://stackoverflow.com/questions/59131976/render-swiftui-view-as-an-uiimage – hayesk Jul 02 '21 at 16:07
-
Thank you, but that solution didn't work, already gone through the same – gagan sharma Jul 02 '21 at 16:10