Commit Graph

142 Commits

Author SHA1 Message Date
Robert Payne fbd807fd09 Alter how insets work when used as implied constant
Using make.left.bottom.equalTo(UIEdgeInsets) will now invert the right and bottom edge.
2016-08-16 23:24:48 +12:00
Robert Payne 7e8c173224 Allow implied superview for equalTo(constant) 2016-08-16 23:24:14 +12:00
Robert Payne 79137bce68 Xcode 8 - Beta 6 2016-08-16 22:53:27 +12:00
Robert Payne a772f08051 Remove unused code 2016-08-16 22:53:17 +12:00
Robert Payne e039522882 Fix OSX deprecation 2016-08-08 11:08:22 +12:00
Robert Payne 6aca61ac93 Add `center` to constraint maker 2016-08-06 23:25:03 +12:00
Robert Payne 1b712cde8c Remove unecessary print statement 2016-08-06 23:24:55 +12:00
Robert Payne 9d0232ca08 API updates, migrate away from iOS 7.0 support 2016-08-06 22:38:02 +12:00
Robert Payne 17a01931db Deprecate priority helpers 2016-08-04 10:57:30 +12:00
Robert Payne f5511c3bac Add in existing update functions and deprecate them 2016-08-04 10:57:23 +12:00
Robert Payne e713b9da5b Add API’s for updating offset/inset/priorty 2016-08-04 10:46:25 +12:00
Robert Payne 200b341492 Add content hugging / compression resistance shortcuts 2016-08-04 10:27:26 +12:00
Robert Payne 8b85ac86d3 Fix missing availability macro 2016-08-04 10:27:15 +12:00
Robert Payne 8fc933a5c2 Fix up legacy deployment and availability of APIs 2016-08-03 14:39:47 +12:00
Robert Payne 4715badfa0 Beta 4 Updates 2016-08-02 19:56:16 +12:00
Robert Payne 9f8ad44677 Add missing remove constraints function content 2016-07-11 21:56:23 -06:00
Robert Payne adab4b821a Deprecate .baseline and migrate to .lastBaseline 2016-07-06 09:08:14 -07:00
Alex Pawlowski b916d75956 Added sensible @discardableResult attributes for ConstraintMaker public functions 2016-06-28 15:55:23 +03:00
Alex Pawlowski d00444d7d1 Migrated to latest Swift 3.0 syntax and latest macOS Cocoa API 2016-06-28 15:31:43 +03:00
Robert Payne 8355410d92 Swift 3.0 Migration 2016-06-15 13:49:49 +12:00
Robert Payne f785886d3a Fix deprecated APIs 2016-05-19 17:02:15 +12:00
Robert Payne d2f259ec5f Bump deprecation notices versioning 2016-05-19 16:54:19 +12:00
Robert Payne 7ba532d597 Major overhaul 2016-01-26 23:49:04 +13:00
Ray Lillywhite 483d525c72 Fix handling of UIEdgeInsets for width and height 2016-01-07 13:52:28 -08:00
Robert Payne 2dcf3bddfa nits 2015-11-08 21:18:01 +13:00
Akiva Leffert 7ae143c3ac Expose location as part of LayoutConstraint for public access 2015-10-14 20:17:59 -04:00
Akiva Leffert 0fe4ad005b Switch makerFile/line to use SourceLocation for consistency
Allows removing redundant default location
2015-10-14 20:17:59 -04:00
Akiva Leffert bbe5b2e49d Instrument each constraint with a source location. 2015-10-14 20:17:59 -04:00
Akiva Leffert 104ce8895c Convert protocol hierarchy to class hierarchy
This has no value unto itself, but is necessary for adding default
arguments to the ConstraintDescriptionRelatable methods, which we'll
need to instrument in source locations.
2015-10-14 20:17:59 -04:00
Akiva Leffert cd49354220 Factor redundant constraint relation code into RelationTarget protocol
Instead of having a copy of each method for each type, factor the
constraint target logic to use a new protocol RelationTarget.

Note that since RelationTarget returns a new ConstraintItem and the
constructor for ConstraintItem is internal, a user will be unable to
erroneously extend the protocol.

LayoutSupport should really be a RelationTarget too, but it seems you
can't extenda a protocol to implement another protocol.
2015-10-14 20:17:59 -04:00
Akiva Leffert a5be9d646b Introduce FloatConvertible to reduce relation boilerplate 2015-10-12 00:57:59 -04:00
Tadeas Kriz e84f9bc1c3 Add compiler condition to remove warnings when not using legacy deployment. 2015-10-04 23:17:48 +02:00
Tadeas Kriz 2afe4d47ec Add call to activateConstraints on iOS8+ and fix build issues for OS X. 2015-10-04 23:04:16 +02:00
Ryan Britton 7fc0537c13 Added tvOS checks so the iOS paths are used rather than OS X 2015-09-24 21:37:33 -07:00
Akiva Leffert 16090bde5d Add support for the iOS 9 Layout Anchor API. 2015-09-23 14:14:16 -04:00
Robert Payne ba26480317 Fixed iOS 9 layout guides, and better support for legacy platforms 2015-09-22 19:38:50 +12:00
Robert Payne de954c0c12 Merge branch 'develop' of github.com:SnapKit/SnapKit into develop
# Conflicts:
#	Source/ConstraintAttributes.swift
2015-09-19 12:37:23 +12:00
Robert Payne 210bab97c7 Enforce availablility for iOS 8.0+ Attributes 2015-09-19 12:21:42 +12:00
Suyeol Jeon ba03f22eb8 Add availability check for iOS 8 and OS X 10.10 methods.
- `NSLayoutConstraint.activateConstraints(_:)`
- `NSLayoutConstraint.deactivateConstraints(_:)`
2015-09-18 13:18:28 +09:00
Suyeol Jeon 8e6219ef86 Add availability check for iOS 8 attributes. 2015-09-14 22:31:55 +09:00
Robert Payne 446e5c5758 Merged in 0.13.0 changes 2015-07-30 19:35:48 +12:00
Ben Jones 88021b8280 Change += and -= to use inPlace ops and += should be union 2015-07-30 19:30:56 +12:00
Ben Jones 5afd216e21 Handle new NSLayoutAttribute FirstBaseline that is introduced in OS X 10.11 for CGPoint or EdgeInsets 2015-07-30 19:30:56 +12:00
Ben Jones c6b3ecaad8 Fixes for Swift 2.0 b2 2015-07-30 19:30:56 +12:00
Robert Payne c1de30ac5c Updated for Swift 2.0 2015-07-30 19:30:56 +12:00
Robert Payne 37b18d44de `insets` is now `inset` and accepts EdgeInsets as well single values 2015-07-30 19:01:33 +12:00
Robert Payne 9ef9ae6f9f Improve debugging and allow width/height constraints to be installed on from view 2015-07-30 18:49:47 +12:00
Robert Payne 3d9a449e37 Merge pull request #122 from alexanderjarvis/master
Fix crash
2015-07-04 10:41:36 +12:00
Alex Jarvis 8269bcea63 Fix crash 2015-06-30 14:25:25 +01:00
Robert Payne 6f0584f855 Update ViewController+SnapKit.swift
Removed unecessary typealias
2015-06-03 15:34:53 +12:00
Robert Payne 6252444966 Added support for view controller layout guides 2015-05-30 19:54:43 +12:00
Robert Payne 62b058de00 Remove unecessary API prefixes 2015-05-30 19:45:39 +12:00
Robert Payne 57baa96dc7 Removed 'final' declaration in attempt to fix odd crashes 2015-04-23 00:31:40 +12:00
Robert Payne e2112b3ab8 Loosen API a bit to better allow chaining order 2015-04-16 10:07:51 +12:00
Robert Payne 931eb01de9 Ensure ConcreteConstraint cannot be subclassed 2015-04-15 23:32:47 +12:00
Robert Payne 5d5bc09b25 Use an abstract superclass for Constraint rather than protocol 2015-04-15 23:31:03 +12:00
Robert Payne 16f6fa789a Fix OS X complaining about edge insets 2015-04-15 23:30:46 +12:00
Robert Payne d9424975d4 Fix OS X compiles 2015-04-15 23:17:20 +12:00
Robert Payne 51662d58bb Snap is now SnapKit 2015-04-15 23:07:50 +12:00
Robert Payne 529e7588aa Update fatal errors 2015-04-12 23:44:32 +12:00
Robert Payne 2b00e7b50c Refactor Constraint -> ConcreteConstraint & Add Updaters! 2015-04-12 23:32:03 +12:00
Robert Payne c9b89ad974 Refactoring & Documentation 2015-04-12 22:21:02 +12:00
Robert Payne 7cb3a61c14 Revert insets to inset 2015-04-12 18:35:29 +12:00
Robert Payne b0c5280e16 Rename insets -> inset and deprecate insets 2015-04-12 18:27:52 +12:00
Robert Payne 18851b7ecd Fix up interface layout direction 2015-04-12 18:27:36 +12:00
Robert Payne 997e0e5970 Remove config and simplify offset/constant differences 2015-04-12 17:54:11 +12:00
Robert Payne 93febd2e5e Update comments 2015-04-12 17:53:48 +12:00
Robert Payne a6790f13c7 Add missing right property from ConstraintBuilderExtendable 2015-04-12 17:53:32 +12:00
Robert Payne 509d648818 Updated API & Copyrights 2015-04-12 00:04:36 +12:00
Robert Payne 931d6ca7ec Initial Implementation of protocol API 2015-04-11 23:39:12 +12:00
Robert Payne 846d767cbb Tidy up how constants are made 2015-04-11 22:16:50 +12:00
Robert Payne 03ba3d603e Added better offset/constant maths 2015-04-11 22:10:02 +12:00
Robert Payne 8f70c8290a Added configuration and InterfaceLayoutDirection 2015-04-11 22:09:44 +12:00
Robert Payne 8b8372c43d Ensure OS X target up to date 2015-04-11 21:47:27 +12:00
Robert Payne 3c3a76cf6e Added activate/deactivate 2015-04-11 21:44:46 +12:00
Robert Payne ded4778181 Fix debugging compile error 2015-04-11 21:44:39 +12:00
Robert Payne 7205e043e8 Updated debugging 2015-04-11 21:27:46 +12:00
Robert Payne 08ff0472b2 Added better debugging support
Support for snp_label and better descriptions when printing LayoutConstraint's
2015-04-11 20:33:13 +12:00
Robert Payne d5e5cf1296 Tidy up priority medium for OS X 2015-04-11 19:44:11 +12:00
Robert Payne 4904b40bfa Added medium priority 2015-04-11 19:43:20 +12:00
Robert Payne 656920acd3 Added support on constraint maker for iOS 8 properties 2015-04-11 19:41:10 +12:00
Robert Payne 2dec123ce0 Tweaked uninstalling constraints and removed unused code blocks 2015-04-11 18:32:33 +12:00
Robert Payne ebe9bb1e8d Further tweaks and improvements 2015-04-11 17:45:59 +12:00
Robert Payne 62c0318c00 Modernize syntax & improve performance 2015-04-11 17:41:05 +12:00
Robert Payne d04d78979e Merge branch 'develop' of github.com:Masonry/Snap into develop
# Conflicts:
#	Source/View+Snap.swift
2015-04-11 17:14:52 +12:00
Robert Payne b014ab638a Finalise classes 2015-04-11 17:13:02 +12:00
Robert Payne 0126a0efc2 Fix up formatting 2015-04-11 17:12:05 +12:00
Robert Payne a31df70146 Merge pull request #71 from Reflejo/cosmetics-changes-swift-1.2
Simplifications and swift 1.2 syntax
2015-04-11 17:07:51 +12:00
Martin Conte Mac Donell 9cec048c44 @noescape on methods 2015-04-10 21:15:40 -07:00
Martin Conte Mac Donell fe5fff0d5d Simplifications and swift 1.2 syntax 2015-04-10 21:11:20 -07:00
Robert Payne 1e5cdba18d Fix Xcode Beta 3 compiler error 2015-03-24 23:09:25 +13:00
Robert Payne c5bab635ec Re-organized Project 2015-03-24 11:39:41 +13:00