O'Reilly logo

Learning iOS Development: A Hands-on Guide to the Fundamentals of iOS Programming by Erica Sadun, Rod Strougo, Maurice Sharp

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Scrolling Basics

Small screens make smartphones portable. They also limit the amount of information you can show. Sometimes information is bigger than the screen—for example a picture, a form with text fields, or a map.

On iOS, the solution is to scroll around. UIScrollView is a virtual window onto larger content. It provides all the support a user needs: dragging content around, zooming in and out, and all the other functionality an app might need.

The user drags or flicks a finger in a scroll view to slide the content around under a fixed “window.” Figure 6-1 shows changing what part of the content is viewed. The blue rectangle is what the user sees on an iOS device screen. The larger image is contained by the scroll view. The left side shows ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required