Category: iOS9

Understand and Use Closures in Swift

Have you ever seen some factory method in UIKit and see this strange parameter called completion or completionHandler? Usually you put nil there and leave it alone. These strange things like (Double,Double) -> Bool things are closures. Closures are functions you use as types,… Continue Reading “Understand and Use Closures in Swift”

How to Read CSV files from the Web in Swift

There’s a lot of data out there for the taking, if you only know how to get it.  There is a treasure trove of  government-based data sets available to the public. There’s a lot of information free for the taking you might want to… Continue Reading “How to Read CSV files from the Web in Swift”

Adding Annotations and Overlays to Maps

In the last lesson, we explored the  joys of making maps using the UIMapView and MapKit. While showing maps is great, we often want to add things to a map, such as locations and graphics.  These are known as Annotations and Overlays. In this lesson… Continue Reading “Adding Annotations and Overlays to Maps”

How to Use MapKit for 2D and 3D Map Views.

Everyone may remember when Apple first introduced MapKit to replace Google Maps on iPhones, they ended up to apologizing. However over time, developers have found how easy it is to use MapKit. This API provides features which make using  both 2D and 3D maps… Continue Reading “How to Use MapKit for 2D and 3D Map Views.”

Adding Actions to iOS and WatchOS Local Notifications

Even if you never want to make an app for the Apple Watch, there’s one place you might want to think about supporting: Notifications. In a previous lesson, we explored how to make local notifications for iOS devices. That lesson ended with a free… Continue Reading “Adding Actions to iOS and WatchOS Local Notifications”

Adding iOS Local Notifications in Swift

The word notification gets a bit abused in the world of mobile development, especially in the world of Apple development. Notifications could mean internal notifications, where classes use observers to watch unrelated code. When a notification appears, the observer code executes special code for… Continue Reading “Adding iOS Local Notifications in Swift”

The Step by Step Guide to Custom Presentation Controllers

Ever wanted that sliding sidebar or an alert with a image picker? Apple has many great ways of presenting view controllers,  but sometimes we want something different, something new. For that we subclass UIPresentationController. However there’s a few concepts that you’ll need to wrap… Continue Reading “The Step by Step Guide to Custom Presentation Controllers”

The Complete Table Tutorial for WatchOS2

In last week’s tutorial of this series, we made a simple dynamic table for the Apple Watch and demonstrated static scrolling tables.Based on some running pace data, we displayed the pace I ran at the mile splits. Many apps will need more than what… Continue Reading “The Complete Table Tutorial for WatchOS2”

Using Settings Bundles with Swift

Have you ever wondered how to put  user defined settings for your app into the settings app?  Xcode can create a special property list called a settings bundle which can append the  NSUserDefaults with more entries from Settings App.  You’ll find out in this… Continue Reading “Using Settings Bundles with Swift”

Using WatchOS2 Navigation in Swift

It’s rare to have a one controller application, even in something as small as the Apple watch. Multiple View Controllers, or Interface Controllers as they are called in WatchKit, need ways to move between controllers. WatchOS2 has a simplified version of the iOS navigation… Continue Reading “Using WatchOS2 Navigation in Swift”