Skip to content

Commit

Permalink
Upgrade project format, prepare for v1.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Gavin Bunney committed Nov 26, 2017
1 parent 72797fb commit dc02292
Show file tree
Hide file tree
Showing 11 changed files with 26 additions and 26 deletions.
2 changes: 1 addition & 1 deletion Source/Toucan-Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>0.6</string>
<string>1.0</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
Expand Down
2 changes: 1 addition & 1 deletion Source/Toucan.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// Toucan.h
//
// Copyright (c) 2014-2017 Gavin Bunney, Bunney Apps (http://bunney.net.au)
// Copyright (c) 2014-2017 Gavin Bunney
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
Expand Down
2 changes: 1 addition & 1 deletion Source/Toucan.swift
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// Toucan.swift
//
// Copyright (c) 2014-2017 Gavin Bunney, Bunney Apps (http://bunney.net.au)
// Copyright (c) 2014-2017 Gavin Bunney
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
Expand Down
2 changes: 1 addition & 1 deletion Source/tvOS/Toucan.tvOS-Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>0.6</string>
<string>1.0</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
Expand Down
2 changes: 1 addition & 1 deletion Source/tvOS/ToucanTVOS.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// ToucanTVOS.h
//
// Copyright (c) 2014-2017 Gavin Bunney, Bunney Apps (http://bunney.net.au)
// Copyright (c) 2014-2017 Gavin Bunney
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
Expand Down
2 changes: 1 addition & 1 deletion Tests/MaskingTests.swift
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) 2014-2017 Gavin Bunney, Bunney Apps (http://bunney.net.au)
// Copyright (c) 2014-2017 Gavin Bunney
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
Expand Down
2 changes: 1 addition & 1 deletion Tests/ResizeTests.swift
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) 2014-2017 Gavin Bunney, Bunney Apps (http://bunney.net.au)
// Copyright (c) 2014-2017 Gavin Bunney
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
Expand Down
2 changes: 1 addition & 1 deletion Tests/ToucanTestCase.swift
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) 2014-2017 Gavin Bunney, Bunney Apps (http://bunney.net.au)
// Copyright (c) 2014-2017 Gavin Bunney
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
Expand Down
14 changes: 7 additions & 7 deletions Toucan.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
archiveVersion = 1;
classes = {
};
objectVersion = 46;
objectVersion = 48;
objects = {

/* Begin PBXBuildFile section */
Expand Down Expand Up @@ -231,7 +231,7 @@
attributes = {
LastSwiftUpdateCheck = 0700;
LastUpgradeCheck = 0910;
ORGANIZATIONNAME = "Simple Labs";
ORGANIZATIONNAME = "Gavin Bunney";
TargetAttributes = {
740AC3E91999799900AB9A86 = {
CreatedOnToolsVersion = 6.0;
Expand All @@ -248,7 +248,7 @@
};
};
buildConfigurationList = 740AC3E41999799900AB9A86 /* Build configuration list for PBXProject "Toucan" */;
compatibilityVersion = "Xcode 3.2";
compatibilityVersion = "Xcode 8.0";
developmentRegion = English;
hasScannedForEncodings = 0;
knownRegions = (
Expand Down Expand Up @@ -452,7 +452,7 @@
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = co.thesimplelab.Toucan;
PRODUCT_BUNDLE_IDENTIFIER = com.github.gavinbunney.Toucan;
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = YES;
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
Expand All @@ -475,7 +475,7 @@
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = co.thesimplelab.Toucan;
PRODUCT_BUNDLE_IDENTIFIER = com.github.gavinbunney.Toucan;
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = YES;
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
Expand Down Expand Up @@ -529,7 +529,7 @@
INFOPLIST_FILE = "$(SRCROOT)/Source/tvOS/Toucan.tvOS-Info.plist";
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = co.thesimplelab.Toucan.tvOS;
PRODUCT_BUNDLE_IDENTIFIER = com.github.gavinbunney.Toucan.tvOS;
PRODUCT_NAME = Toucan;
SDKROOT = appletvos;
SKIP_INSTALL = YES;
Expand All @@ -556,7 +556,7 @@
INFOPLIST_FILE = "$(SRCROOT)/Source/tvOS/Toucan.tvOS-Info.plist";
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = co.thesimplelab.Toucan.tvOS;
PRODUCT_BUNDLE_IDENTIFIER = com.github.gavinbunney.Toucan.tvOS;
PRODUCT_NAME = Toucan;
SDKROOT = appletvos;
SKIP_INSTALL = YES;
Expand Down
18 changes: 9 additions & 9 deletions ToucanPlayground.playground/Contents.swift
Original file line number Diff line number Diff line change
Expand Up @@ -50,25 +50,25 @@ Toucan(image: portraitImage!).resize(CGSize(width: 500, height: 500), fitMode: T
// Masking
// ------------------------------------------------------------

let landscapeCropped = Toucan(image: landscapeImage!).resize(CGSize(width: 500, height: 500), fitMode: Toucan.Resize.FitMode.crop).image
let landscapeCropped = Toucan(image: landscapeImage!).resize(CGSize(width: 500, height: 500), fitMode: Toucan.Resize.FitMode.crop).image!

// We can mask with an ellipse!
Toucan(image: landscapeImage!).maskWithEllipse().image

// Demonstrate creating a circular mask -> resizes to a square image then mask with an ellipse
Toucan(image: landscapeCropped).maskWithEllipse().image
Toucan(image: landscapeCropped).maskWithEllipse().image!

// Mask with borders too!
Toucan(image: landscapeCropped).maskWithEllipse(borderWidth: 10, borderColor: UIColor.yellow).image
Toucan(image: landscapeCropped).maskWithEllipse(borderWidth: 10, borderColor: UIColor.yellow).image!

// Rounded Rects are all in style
Toucan(image: landscapeCropped).maskWithRoundedRect(cornerRadius: 30).image
Toucan(image: landscapeCropped).maskWithRoundedRect(cornerRadius: 30).image!

// And can be fancy with borders
Toucan(image: landscapeCropped).maskWithRoundedRect(cornerRadius: 30, borderWidth: 10, borderColor: UIColor.purple).image
Toucan(image: landscapeCropped).maskWithRoundedRect(cornerRadius: 30, borderWidth: 10, borderColor: UIColor.purple).image!

// Masking with an custom image mask
Toucan(image: landscapeCropped).maskWithImage(maskImage: octagonMask!).image
Toucan(image: landscapeCropped).maskWithImage(maskImage: octagonMask!).image!

//testing the path stuff
let path = UIBezierPath()
Expand All @@ -77,18 +77,18 @@ path.addLine(to: CGPoint(x: 50, y: 0))
path.addLine(to: CGPoint(x: 100, y: 50))
path.addLine(to: CGPoint(x: 50, y: 100))
path.close()
Toucan(image: landscapeCropped).maskWithPath(path: path).image
Toucan(image: landscapeCropped).maskWithPath(path: path).image!

Toucan(image: landscapeCropped).maskWithPathClosure(path: {(rect) -> (UIBezierPath) in
return UIBezierPath(roundedRect: rect, cornerRadius: 50.0)
}).image
}).image!


// ------------------------------------------------------------
// Layers
// ------------------------------------------------------------

// We can draw ontop of another image
Toucan(image: portraitImage!).layerWithOverlayImage(octagonMask!, overlayFrame: CGRect(x: 450, y: 400, width: 200, height: 200)).image
Toucan(image: portraitImage!).layerWithOverlayImage(octagonMask!, overlayFrame: CGRect(x: 450, y: 400, width: 200, height: 200)).image!


4 changes: 2 additions & 2 deletions ToucanPlayground.playground/timeline.xctimeline
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@
version = "3.0">
<TimelineItems>
<LoggerValueHistoryTimelineItem
documentLocation = "file:///Users/gbunney/dev/Toucan/ToucanPlayground.playground#CharacterRangeLen=62&amp;CharacterRangeLoc=3428&amp;EndingColumnNumber=0&amp;EndingLineNumber=80&amp;StartingColumnNumber=1&amp;StartingLineNumber=79&amp;Timestamp=533352592.488941"
documentLocation = "file:///Users/gbunney/dev/Toucan/ToucanPlayground.playground#CharacterRangeLen=63&amp;CharacterRangeLoc=3434&amp;EndingColumnNumber=0&amp;EndingLineNumber=80&amp;StartingColumnNumber=1&amp;StartingLineNumber=79&amp;Timestamp=533378462.520809"
selectedRepresentationIndex = "0"
shouldTrackSuperviewWidth = "NO">
</LoggerValueHistoryTimelineItem>
<LoggerValueHistoryTimelineItem
documentLocation = "file:///Users/gbunney/dev/Toucan/ToucanPlayground.playground#CharacterRangeLen=158&amp;CharacterRangeLoc=3492&amp;EndingColumnNumber=0&amp;EndingLineNumber=84&amp;StartingColumnNumber=1&amp;StartingLineNumber=81&amp;Timestamp=533352592.489106"
documentLocation = "file:///Users/gbunney/dev/Toucan/ToucanPlayground.playground#CharacterRangeLen=159&amp;CharacterRangeLoc=3499&amp;EndingColumnNumber=0&amp;EndingLineNumber=84&amp;StartingColumnNumber=1&amp;StartingLineNumber=81&amp;Timestamp=533378462.520995"
selectedRepresentationIndex = "0"
shouldTrackSuperviewWidth = "NO">
</LoggerValueHistoryTimelineItem>
Expand Down

0 comments on commit dc02292

Please sign in to comment.