Quantcast
Channel: Make a grid of buttons of same width and height in SwiftUI - Stack Overflow
Browsing latest articles
Browse All 2 View Live

Image may be NSFW.
Clik here to view.

Answer by piebie for Make a grid of buttons of same width and height in SwiftUI

How about using a GeometryReader(docs here)? They give the dimensions of their parent view to the children. Here's a partial implementation based on what you already have:import SwiftUIstruct...

View Article



Image may be NSFW.
Clik here to view.

Make a grid of buttons of same width and height in SwiftUI

I'm trying to create a Calculator using SwiftUI, I'm struggling right now on creating the Grid of buttons to fill the available space horizontallyRight now I'm just trying to make the buttons fill a...

View Article
Browsing latest articles
Browse All 2 View Live




Latest Images