Category: ios7
-
The Swift Swift Tutorial: Ten Points for Using Optionals.
In the first month and a half of using Swift, I could argue the optional value is the most difficult new concept. It isn’t hard, just something different to wrap one’s head around. That Apple’s documentation peppers information about optionals in two different e-books without consolidating the information doesn’t help. I decided to combine what…
-
The Swift Swift Tutorial: How to Use UITableView in Swift
[Converted to to Swift 2.0/iOS9 9/28/15 SJL] The workhorse control in iOS is the table view. With both a delegate and data source it is powerful, flexible and can get a bit complicated. In this lesson, we will add a table view controller between the Pizza Demo and the Edit Price scenes in our earlier…
-
The Swift Swift Tutorial: Adding an MVC Model Class in Swift
[Note: Updated for Swift 2.0/iOS9 9/1/15 SJL] Last time we built a small application to compute the area of a pizza. Since it was missing a model, we are going to make an improved version of the application and add a model class, plus make a few UI changes. Since there are so many changes,…
-
The Slippy Flippy Challenge: Make Marquee Style Scrolling Backgrounds
To give a sense of motion in a game one can use parallax backgrounds. Such backgrounds are in constant motion, but at a different rate than the foreground motion. In Slippy Flippy, we use ice floating by on the water for such an effect. While this seems rather complicated, it is not as difficult as…
-
The Swift Swift Tutorial:A Swift Pizza App with UI
[Updated to Swift 2.0 8/30/15] I thought I’d do some writing for the advanced beginner to intermediate level programmer. That’s a loose definition, but I’ll define it as someone who can find their way around Xcode well enough that I can say “open a single view template and add two buttons and a label” and…
-
From Brackets to Braces: We will have UI!!!
One of the things about working with an iPhone is that you can use its cool UI. One of the thing I Have been struggling to write the Swift programming tutorials is that said UI was off-limits by the Apple confidentiality agreement. After writing the print and println tutorials this morning, I looked up the confidentiality agreement…
-
From Brackets to Braces in Swift: Constants and Comments
In this series of posts, I’m going to explain much of Apple’s new Swift programming language. It assumes you have no earlier programming knowledge or need to brush up on a few concepts to get things working. Since the Publication of the Book The C Programming Language by Kernigan and Ritchie many decades ago, everyone…
-
WWDC Is Not CES
A few weeks ago, I was talking to friend about the Stopwatch I had written in Sprite Kit. At the time I had the stopwatch working to tenths of a second. While I was discussing this stopwatch on social media, a friend of mine bragged that their stopwatch app they downloaded somewhere goes to hundredths…
-
Make a Clock In Sprite Kit: Adding a Button for a Stopwatch
In the clock app so far, we have a date and a time. We can switch between them by tapping the screen of our phone. Most apps use a button for this, and it’s time we added our first button. Our app will now change to a stopwatch mode when we press the button. Re-position…