Changes

Jump to: navigation, search
m
Text replacement - "<table border="0" cellspacing="0"> " to "<table border="0" cellspacing="0" width="100%">"
<table border="0" cellspacing="0" width="100%"><tr>
<td width="20%">[[Writing iOS 4 Code to Hide the iPad Keyboard (Xcode 4)|Previous]]<td align="center">[[IPad iOS 4 App development Essentials - Xcode 4 Edition|Table of Contents]]<td width="20%" align="right">[[iOS 4 iPad Rotation, View Resizing and Layout Handling (Xcode 4)|Next]]</td>
<tr>
<td width="20%">Writing iOS 4 Code to Hide the iPad Keyboard (Xcode 4)<td align="center"><td width="20%" align="right">iOS 4 iPad Rotation, View Resizing and Layout Handling (Xcode 4)</td>
</table>
<hr>
 
 
<htmlet>ios9_upgrade</htmlet>
 
 
In the preceding chapters we have created a number of user interfaces in the course of building our example iOS 4 iPad applications. In doing so, we have been using views and windows without actually providing much in the way of explanation. Before moving on to other topics, however, it is important to have a clear understanding of the concepts behind the way that iPad user interfaces are constructed and managed. In this chapter we will cover the concepts of views, windows and view hierarchies.
<googlehtmlet>ADSDAQBOX_FLOWadsdaqbox_flow</googlehtmlet>
[[Image:iphone_view_hierarchy.jpg|An example of an iPad user interface view hierarchy]]
[[Image:ipad_view_heirachy_user_interface.jpg|An iPad user interface illustrating the view hierarchy]]
<htmlet>ios9_upgrade</htmlet>
In this example, the UIWindow instance is not visible because it is fully obscured by the blue UIView1 instance. Displayed on top of, and within the frame of, UIView1 are the UIButton1, UILabel and yellow UIView2 subviews. Displayed on top of, and within the frame of, UIView2 are its respective subviews, namely UIButton2 and UIImageView.
In this chapter we have explored the concepts of using views in terms of constructing an iPad application user interface and also how these views relate to each other within the context of a view hierarchy. We have also discussed how the view hierarchy dictates issues such as the positioning and resize behavior of subviews and defines the response chain for the user interface.
 
 
<htmlet>ios9_upgrade</htmlet>
 
 
<hr>
<table border="0" cellspacing="0" width="100%"><tr>
<td width="20%">[[Writing iOS 4 Code to Hide the iPad Keyboard (Xcode 4)|Previous]]<td align="center">[[IPad iOS 4 App development Essentials - Xcode 4 Edition|Table of Contents]]<td width="20%" align="right">[[iOS 4 iPad Rotation, View Resizing and Layout Handling (Xcode 4)|Next]]</td>
<tr>
<td width="20%">Writing iOS 4 Code to Hide the iPad Keyboard (Xcode 4)<td align="center"><td width="20%" align="right">iOS 4 iPad Rotation, View Resizing and Layout Handling (Xcode 4)</td>
</table>

Navigation menu