Latest | 1.1 |
---|---|
Homepage | https://github.com/Ovrchk/OVUIKitHelper |
License | MIT |
Platforms | ios 8.0 |
Authors |
Getting/setting UIView
‘s position and sizing becomes much easier with OVUIKitHelper
! OVUIKitHelper
adds top, left, bottom and right properties to UIView
, so now you can manage its instances frame like never before. This helper also includes layout methods with which you can easily align any view relatively to its superview, or any other view.
Example
let view = UIView.init()
//we can set view's x and y coordinate much easier
view.left = 10
view.top = 30
//or we can align our view with any other view
view.right = someView.left - 20
view.bottom = someView.bottom
//also we can automatically align (even with paddings) view inside its container view if nessessary
view.alignInSuperview(horizontalAlignment: .right, verticalAlignment: .bottom, padding: UIEdgeInsets.init(nil, nil, 15, 5))
To run the example project, clone the repo, and run pod install
from the Example directory first.
Installation
OVUIKitHelper is available through CocoaPods. To install
it, simply add the following line to your Podfile:
pod 'OVUIKitHelper'
Author
Dmitry Overchuk, [email protected]
License
OVUIKitHelper is available under the MIT license. See the LICENSE file for more info.
Latest podspec
{ "name": "OVUIKitHelper", "version": "1.1", "summary": "UIView swift extension which helps manage its position, size, or alignment", "description": "Getting/setting UIView's position and sizing becomes much easier with OVUIKitHelper! OVUIKitHelper adds top, left, bottom and right properties to UIView, so now you can manage its instances frame like never before. This helper also includes layout methods with which you can easily align any view relatively to its superview, or any other view.", "homepage": "https://github.com/Ovrchk/OVUIKitHelper", "license": { "type": "MIT", "file": "LICENSE" }, "authors": { "Ovrchk": "[email protected]" }, "source": { "git": "https://github.com/Ovrchk/OVUIKitHelper.git", "tag": "1.1" }, "platforms": { "ios": "8.0" }, "source_files": "OVUIKitHelper/Classes/**/*" }
Sun, 14 Jan 2018 08:00:04 +0000