Layout Margins are not respected when set in init

Originator:kpa
Number:rdar://32422549 Date Originated:26-May-2017 11:41 AM
Status:Duplicate 25230530 Resolved:
Product:iOS + SDK Product Version:10
Classification:Serious Bug Reproducible:Always
 
Summary:
When layout margins are set and the view is constrained in init, the layout margins are not respected.

Steps to Reproduce:
1. Create a UIView subclass
2. Override init and set custom layout margins
3. Constrain a subview to the layout margins guides

Expected Results:
The subview to be inset according to the layout margins

Actual Results:
The subview is not inset

Version:
10

Notes:
n.a.

Comments

Klaas Pieter Annema

This is a duplicate of 25230530

Klaas Pieter Annema

Screenshot attached.

Apple Developer Relations

Can you please attach a screenshot of what you are seeing? Thank you.

macOS Screenshots Instructions: https://developer.apple.com/services-account/download?path=/OS_X/OS_X_Logs/Screen_Recording_Instructions.pdf


For a complete list of logging instructions visit: https://developer.apple.com/bug-reporting/profiles-and-logs/


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!