Category: iOS

  • Working with MapKit Local Search in iOS 17

    This chapter will explore using the iOS MapKit MKLocalSearchRequest class to search for map locations within an iOS app. The example app created in the chapter, Working with Maps on iOS 17 with MapKit and the MKMapView Class will then be extended to demonstrate local search in action. An Overview of iOS Local Search Local…

  • Using Storyboards in Xcode 15

    Storyboarding is a feature built into Xcode that allows the various screens that comprise an iOS app and the navigation path through those screens to be visually assembled. Using the Interface Builder component of Xcode, the developer drags and drops view and navigation controllers onto a canvas and designs the user interface of each view…

  • Working with Maps on iOS 17 with MapKit and the MKMapView Class

    In the preceding chapters, we spent some time looking at handling raw geographical location information in the form of longitude, latitude, and altitude data. The next step is to learn about the presentation of location information to the user through maps and satellite images. Therefore, this chapter aims to provide an overview of the steps…

  • Using Trait Variations to Design Adaptive iOS 17 User Interfaces

    In 2007 developers only had to design user interfaces for single screen size and resolution (that of the first generation iPhone). However, considering the range of iOS devices, screen sizes, and resolutions available today, designing a single user interface layout to target the full range of device configurations now seems a much more daunting task.…

  • An Example iOS 17 Location App

    Having covered the basics of location management in iOS 17 apps in the previous chapter, we can put theory into practice and work step-by-step through an example app. This chapter aims to create a simple iOS app that tracks the latitude, longitude, and altitude of an iOS device. In addition, the level of location accuracy…

  • Understanding the iOS 17 Auto Layout Visual Format Language

    The third and final option for creating Auto Layout constraints involves a combination of code and the visual format language. This chapter aims to introduce the visual format language and work through code samples demonstrating the concept in action. Introducing the Visual Format Language The visual format language is not a new programming language in…

  • Implementing Cross-Hierarchy Auto Layout Constraints in iOS 17

    One of the few types of Auto Layout constraints that cannot be implemented within the Interface Builder environment references views contained in different view hierarchies. Constraints of this type must, therefore, be implemented in code. Fortunately, however, the steps to achieve this are quite simple. The objective of this chapter is to work through an…

  • Implementing iOS 17 Auto Layout Constraints in Code

    In addition to using Interface Builder, it is also possible to create Auto Layout constraints directly within the code of an app. These approaches, however, are not necessarily mutually exclusive. There are, for example, situations where a layout will be constructed using a combination of Interface Builder and manual coding. Furthermore, some types of constraint…

  • Working with iOS 17 Auto Layout Constraints in Interface Builder

    By far, the most productive and intuitive way to work with constraints is using the Auto Layout features of Interface Builder. Not only does this avoid the necessity to write time-consuming code (though for complex layout requirements, some code will be inevitable), but it also provides instant visual feedback on constraints as they are configured.…

  • An Introduction to Auto Layout in iOS 17

    Arguably one of the most important parts of designing the user interface for an app involves getting the layout correct. In an ideal world, designing a layout would consist of dragging view objects to the desired location on the screen and fixing them at these positions using absolute X and Y screen coordinates. However, in…