All Projects → dimix → StoryboardConstraint

dimix / StoryboardConstraint

Licence: MIT license
A simple way to use programmatically Autolayout Constraint created in Storyboard.

Programming Languages

swift
15916 projects
ruby
36898 projects - #4 most used programming language

Projects that are alternatives of or similar to StoryboardConstraint

wwlayout
Swifty DSL for programmatic Auto Layout in iOS
Stars: ✭ 46 (+84%)
Mutual labels:  constraints, autolayout, autolayout-constraints
EZAnchor
An easier and faster way to code Autolayout
Stars: ✭ 25 (+0%)
Mutual labels:  constraints, autolayout
Core Layout
Flexbox & CSS-style Layout in Swift.
Stars: ✭ 215 (+760%)
Mutual labels:  constraints, autolayout
Stevia
🍃 Concise Autolayout code
Stars: ✭ 3,182 (+12628%)
Mutual labels:  constraints, autolayout
Kvconstraintkit
An Impressive Auto Layout DSL for iOS, tvOS & OSX. & It is written in pure swift.
Stars: ✭ 91 (+264%)
Mutual labels:  constraints, autolayout
Driftwood
Driftwood is a DSL to make Auto Layout easy on iOS, tvOS and macOS.
Stars: ✭ 14 (-44%)
Mutual labels:  constraints, autolayout
Swiftautolayout
Write constraints in a concise, expressive, Swifty way.
Stars: ✭ 83 (+232%)
Mutual labels:  constraints, autolayout
Mylinearlayout
MyLayout is a powerful iOS UI framework implemented by Objective-C. It integrates the functions with Android Layout,iOS AutoLayout,SizeClass, HTML CSS float and flexbox and bootstrap. So you can use LinearLayout,RelativeLayout,FrameLayout,TableLayout,FlowLayout,FloatLayout,PathLayout,GridLayout,LayoutSizeClass to build your App 自动布局 UIView UITab…
Stars: ✭ 4,152 (+16508%)
Mutual labels:  constraints, autolayout
Uicollectionview Layouts Kit
📐 A set of custom layouts for UICollectionView with examples [Swift 5.3, iOS 12].
Stars: ✭ 410 (+1540%)
Mutual labels:  constraints, autolayout
Easyswiftlayout
Lightweight Swift framework for Apple's Auto-Layout
Stars: ✭ 345 (+1280%)
Mutual labels:  constraints, autolayout
VanillaConstraints
🍦 Simplified and chainable AutoLayout constraints for iOS.
Stars: ✭ 42 (+68%)
Mutual labels:  constraints, autolayout
Tangramkit
TangramKit is a powerful iOS UI framework implemented by Swift. It integrates the functions with Android layout,iOS AutoLayout,SizeClass, HTML CSS float and flexbox and bootstrap. So you can use LinearLayout,RelativeLayout,FrameLayout,TableLayout,FlowLayout,FloatLayout,LayoutSizeClass to build your App 自动布局 UIView UITableView UICollectionView
Stars: ✭ 984 (+3836%)
Mutual labels:  constraints, autolayout
Align
Intuitive and powerful Auto Layout library
Stars: ✭ 261 (+944%)
Mutual labels:  constraints, autolayout
Snapkit
A Swift Autolayout DSL for iOS & OS X
Stars: ✭ 18,091 (+72264%)
Mutual labels:  constraints, autolayout
Easyanchor
⚓️ Declarative, extensible, powerful Auto Layout
Stars: ✭ 432 (+1628%)
Mutual labels:  constraints, autolayout
Fluid For Sketch
[Sketch Plugin] Sketch-flavored Auto Layout-like Constraints
Stars: ✭ 2,408 (+9532%)
Mutual labels:  constraints, autolayout
Logician
Logic programming in Swift
Stars: ✭ 182 (+628%)
Mutual labels:  constraints
Snapkitextend
SnapKit的扩展,SnapKit类似于Masonry,但是其没有对Arry的设置和对等间距排列的布局等,此扩展是类似Masonry的写法对SnapKit的补充,同时补充九宫格布局方式
Stars: ✭ 110 (+340%)
Mutual labels:  constraints
Sketch Constraints
📏 A plugin that integrates constraints in Sketch to lay out layers.
Stars: ✭ 1,300 (+5100%)
Mutual labels:  constraints
Joiful
TypeScript Declarative Validation for Joi
Stars: ✭ 177 (+608%)
Mutual labels:  constraints

StoryboardConstraint

A simple way to use programmatically Autolayout Constraint created in Storyboard.

alt tag

Features

  • Predefined basic constraints: top, bottom, leading, trailing, height, width, centerX, centerY
  • A complete method to find a specific constraint through the views

Podfile

To integrate StoryboardConstraint into your Xcode project using CocoaPods, specify it in your Podfile:

source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '9.0'

target 'TargetName' do
  use_frameworks!
  pod 'StoryboardConstraint'
end

Then, run the following command:

$ pod install

How to Use

1. Add UIView+StoryboardConstraint.swift on your project

2. Get the constraints

You can get the constraint set in Storyboard like this:

customView.heightConstraint?.constant = 200
customView.topConstraint?.constant = 20

You can also set a custom constraint identifier and get it like this:

view.constraint(withIdentifier: "customWidth", searchInSubviews: true)?.constant = 50

If you want you can get all the constraints with a specified attribute like this:

view.constraints(withAttribute: .height)

This method returns all the constraints found ordered by priority.

Requirements

Current version is compatible with:

  • Swift 5.0
  • iOS 10 or later
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].