title: How to make group of buttons same width in SwiftUI
body: <p>I have a group of three buttons for media control (jump back, play/pause, jump forward). When I press the play button, the "play" icon is replaced by the "pause" icon which takes a bit less space. As I haven't defined any size constraints, the pause button gets a little bit smaller and causes the other two to move a bit.</p>
  
  <p>How can I make all three buttons the same width without defining any hard constraints as currently the buttons have the perfect size on all different devices?</p>
  
  <p>Simplified code:</p>
  
  <pre><code>HStack {
      Button(action: { }) {
          Image(systemName: "backward.end")
      }.padding().
      viewModel.isPlaying ? Button(action: { }) {
          Image(systemName: "pause")
      }.padding() : Button(action: { }) {
          Image(systemName: "play")
      }.padding()
      Button(action: { }) {
          Image(systemName: "forward.end")
      }.padding()
  }
  </code></pre>