Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add pin.readableMargins and pin.layoutmargins #170

Merged
merged 5 commits into from
Aug 25, 2018
Merged

Conversation

lucdion
Copy link
Member

@lucdion lucdion commented Aug 25, 2018

Add properties:

  • pin.readableMargins: UIEdgeInset:
    PinLayout's UIView.pin.readableMargins property expose UIKit UIView.readableContentGuide as an UIEdgeInsets. This is really useful since UIKit only expose the readableContent area to Auto Layout using UILayoutGuide.

  • pin.layoutmargins: UIEdgeInset
    PinLayout's UIView.pin.layoutMargins property expose directly the value of UIKit UIView.layoutMargins. The property exists only to be consistent with the other areas: pin.safeArea, pin.readableMargins and pin.layoutmargins. So its usage is not necessary.

Add examples using these properties:
pinlayout_example_layout_margins_all

pinlayout_example_tableview_readable_content_all

Luc Dion added 4 commits August 24, 2018 06:20
* `UIView.pin.readableMargins`: Expose UIKit `UIView.readableContentGuide`.
* `UIView.pin.layoutMargins`: Expose UIKit `UIView.layoutMargins` / `UIView.layoutMarginsGuide`.
@lucdion lucdion changed the title Add "pin.readableMargins" and "pin.layoutmargins" Add pin.readableMargins and "pin.layoutmargins" Aug 25, 2018
@lucdion lucdion changed the title Add pin.readableMargins and "pin.layoutmargins" Add pin.readableMargins and pin.layoutmargins Aug 25, 2018
@lucdion lucdion merged commit edf804a into master Aug 25, 2018
@lucdion lucdion deleted the readableMargins branch August 25, 2018 18:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant