Questions tagged [geometryreader]

A container view that defines its content as a function of its own size and coordinate space. Returns a flexible preferred size to its parent layout.

It's a component of Apple's SwiftUI language.

Learn more from Apple's documentation

110 questions
0
votes
1 answer

SwiftUI - Button doesn't work at the top left of the view

I am new in SwiftUI and I am having an issue with my "hamburger" menu. Basically I have created 2 views for the Home page: Home view and Home Side Menu view. My main goal is to put the "hamburger" button at the top left of the view and open the…
Sofia
  • 3
  • 1
  • 2
0
votes
2 answers

How to keep Text as leading alignment after set Text().frame(maxWidth: .infinity)

It could be a simple case, but I couldn't find a solution. Here is my code, using the GeometryReader to set the relative layout of SwiftUI view size like Image. The issue in on the last VStack, I want to background of Text to go to the right end of…
ChuckZHB
  • 656
  • 2
  • 15
0
votes
1 answer

SwiftUI - ScrollView not scrolling all the way to the bottom

I having problems with getting my scroll view to scroll all the way to the bottom. What's odd is that when it's populated with one set of data, it doesn't have this issue, however, in the other data set it gets to the last item and I can't scroll to…
Jason Tremain
  • 861
  • 2
  • 12
  • 27
0
votes
1 answer

SwiftUI + ScrollView not able to add views if it's exceed view height

I am trying to show all the properties of the Text component in a single view. Showing Text with different styles and fonts. For that I am adding multiple Text components in a single view. To make it possible I am using the ScrollView component and…
Kampai
  • 21,517
  • 19
  • 87
  • 90
-1
votes
1 answer

(SwiftUI) How to Read Geometry of a reactive view?

I need to add a view on top of this chat bubble view, like an Instagram emoji reaction. Let's call it EmojiView. It will need to always be in the bottom left or right corner of the chat bubble. But the chat bubble's size will vary with how much text…
1 2 3 4 5 6 7
8