title: How to shrink one padding to provide space for another padding instead in SwiftUI?
body: <p>I have a title, three images and a text button. On smaller screens, I would expect the padding on the title to shrink to provide padding on the text button since I have provided a layout priority hierarchy based via <code>.layoutPriority(..)</code>. Any ideas while the below code is not working?</p>
  <p><a href="https://i.stack.imgur.com/u6YRZh.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/u6YRZh.png" alt="enter image description here" /></a></p>
  <pre><code>import SwiftUI
  import SwiftSVG
  
  struct GenderView: View {
  
      public let didProvideGender: ((_ gender: Gender) -&gt; Void)
      public let didCancel: (() -&gt; Void)
  
      var body: some View {
          VStack (alignment:.center) {
              Text(&quot;Your Gender&quot;)
                  .font(Font.system(size: 40.0, weight: .bold))
                  .fontWeight(.bold)
                  .padding(40.0) // I would expect this to shrink as space becomes less! 
                  .multilineTextAlignment(.center)
                  .layoutPriority(0)
                  .fixedSize(horizontal: false, vertical: false)
              ForEach([Gender.Female, Gender.Male, Gender.NonBinary], id: \.self) { gender in
                  Button(action: {
                      self.didProvideGender(gender)
                  }) {
                      GenderSVG(gender: gender)
                  }.scaledToFit()
                   .frame(width: 150, height: 150)
              }
              Button(action: {
                  self.didCancel()
              }) {
                  Text(&quot;I do not want to provide my gender at this time.&quot;)
                      .font(Font.system(size: 13, weight: .regular))
                      .foregroundColor(Color.black)
                      .underline()
                      .padding(.all, 10)
                      .layoutPriority(1) // Setting higher priority than that of the title!
              }
          }
      }
  }
  
  struct GenderView_Previews: PreviewProvider {
      static var previews: some View {
          GenderView(didProvideGender: { (gender) in
              
          }) {
              
          }
      }
  }
  
  // Below code is just for showing three images; you could replace it with Image(..).
  enum Gender: String {
      case Male
      case Female
      case NonBinary
  }
  
  struct GenderSVG: UIViewRepresentable {
  
      let size: CGSize = CGSize(width: 150, height: 150)
      let gender: Gender
  
      static func bundleSVGName(gender: Gender) -&gt; String {
          switch gender {
          case .Male:
              return &quot;MaleSVG&quot;
          case .Female:
              return &quot;FemaleSVG&quot;
          case .NonBinary:
              return &quot;NonBinarySVG&quot;
          }
      }
  
      func makeUIView(context: Context) -&gt; SVGView {
          let view = SVGView(SVGNamed: GenderSVG.bundleSVGName(gender: gender))
          view.bounds = CGRect(origin: .zero, size: size)
          view.backgroundColor = .white
          return view
      }
  
      func updateUIView(_ view: SVGView, context: Context) {
      }
  
  }
  
  
  </code></pre>