A (175)

(Tuis.) #1
CHAPTER 6: Android Screen Design: Writing to the Display Using Activity and View 211

Figure 6-40. Reducing the hello_world screen title TextView from 48dip to 28dip, to pull second LinearLayout left


If you wanted to put this TextView above the nested , you would need an even more
complicated nested structure, such as the following (pseudo) UI layout container
structure:



UI Screen Title


UI Labels


UI Data Fields



This is why we are going to learn about the layout container in the next chapter, as
it is always desirable to use a single UI layout container rather than using four layout containers and
nesting as we’ve done here to achieve a fairly simple UI design result.


Summary


In this chapter, you learned all about several of the most important Android superclasses that are
used to create Android applications and get them running on the device display screen. These
include the Activity class, the View class, and the ViewGroup class, and the subclasses of these
classes, which are actually used to create your Android applications, such as the LinearLayout
class. You already know you have to write all the Activity subclasses yourself, but as far as the View

Free download pdf