Chapter 4Displaying Your Watch App UI
Our HelloWatch example from the previous chapter worked, but it’s not winning an Apple Design Award any time soon. We need more than just a button and a label in our WatchKit apps. We’re in luck, as WatchKit offers a bevy of built-in user-interface components. These UI components, called interface objects in WatchKit, inherit from the WKInterfaceObject class, similar to UIView in iOS. WatchKit has a unique layout system more akin to HTML tables than iOS views, though. Let’s take a quick tour of interface objects and how they’re used, then explore how they differ from UIView and its subclasses. By the end of this chapter, you’ll have a better understanding of what UI components are available to you in WatchKit, ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access