Most things are possible with Auto Layout, but not always easy.
Here's what I would try (I'm focusing here on just the horizontal arrangement - you will of course need to add constraints for vertical arrangement but that should be easy):
- Create a UIView to act as a container to hold the buttons.
- Constrain this container view to center horizontally within your main view.
- Position your 3 buttons inside the container view:
a. Set width constraints on all the buttons.
b. Constrain first button leading to container leading.
c. Constrain first button trailing to second button leading with however much spacing you want.
d. Constrain second button trailing to last button leading with same spacing as in c.
e. Constrain last button trailing to container trailing.
- Create outlets for the button width constraints and the spacing constraints c. and d. above.
Now, to hide any button, set its width constraint constant to 0 and its nearest spacing constraint to 0. (The middle button has spacing constraints on either side - pick one to set to 0, it does not matter which one.)
To redisplay a button, set the constraint constants back to their original values.