Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Swift iOS Programming for Kids
  • Toc
  • feedback
Swift iOS Programming for Kids

Swift iOS Programming for Kids

By : D. Sommer, Campagno
4.2 (5)
close
Swift iOS Programming for Kids

Swift iOS Programming for Kids

4.2 (5)
By: D. Sommer, Campagno

Overview of this book

This book starts at the beginning by introducing programming through easy to use examples with the Swift Playgrounds app. Kids are regularly encouraged to explore and play with new concepts to support knowledge acquisition and retention – these newly learned skills can then be used to express their own unique ideas. Children will be shown how to create their first iOS application and build their very own movie night application.
Table of Contents (15 chapters)
close
2
2. Getting Set Up
10
10. Pokémon Battle
13
13. Space Pizza Delivery

A deep dive into UI in iOS

In Chapter 11, Simon Says, we created a simple UI with four subviews, each representing a color in the Simon Says memory game. Toward the end of the chapter, we tried to run our application on a device with a different screen size and noted how our UI elements did not scale and the interface ended up looking different from how we wanted it to look. In this section, we will dive deeper into how GUI works in order to come up with a better strategy to lay out our UI.

The view hierarchy

A UI in iOS is built using something we refer to as views. A view represents an element, such as an icon, menu, text field, or a button. A view can have multiple child views or subviews and a view can have one parent view. Let's illustrate this with a simple example:

The view hierarchy

This UI is supposed to look like a chat interface, where the user of the app is able to write messages back and forth with John. Let's go through the different UI...

bookmark search playlist download font-size

Change the font size

margin-width

Change margin width

day-mode

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Delete Bookmark

Modal Close icon
Are you sure you want to delete it?
Cancel
Yes, Delete