Stevik
Stevik

Reputation: 1152

Xcode autolayout - dynamic constraints

In the picture below you can see "prototype" of menu I need to create.

enter image description here

I managed to do it with only single item in the middle, but how can I achieve exactly the same result as you can see in the picture ?

Each circle should be a separate element.

Upvotes: 1

Views: 191

Answers (1)

Ajay Kumar
Ajay Kumar

Reputation: 1827

If I have understood your problem, then following is the solution.

Add following constraints as shown in screenshot, I have also included result achieved in simulator with these constraints in screenshot.

And for setting borderWidth and corner radius I have used run time attributes which is also shown in screenshot.

Edit- Added new ScreenShot.

enter image description here

Upvotes: 1

Related Questions