101
Chapter 4
Introduction to XML: Defining
an Android App, Its Design,
and Constants
In this chapter, we will take a look at how the XML markup language allows application developers,
and more importantly, application designers, to define their Android application’s user interface (UI)
designs, styling, themes, constants, permissions, icons, activities, services, and how they function
within the Google Play e-storefront, all without having any knowledge of Java programming. Of
course, I am going to teach you Java programming in this book, starting with the next chapter, but
you could hire people to do just design and all they would have to know is how to use the XML
language we are going to learn about during this chapter. It is important to note that these same XML
concepts that you will be learning in this chapter apply to both the 32-bit Android 4.4 OS as well as
to the new 64-bit Android 5.0 OS, which you will learn how to develop apps for in Chapter 16.
In the previous chapter, you created the foundation for your HelloUniverse Android application using
Eclipse Android Development Tools (ADT) New Android Application series of dialogs. As part of this
new application creation process, more than a half-dozen XML definition files were created. We are
going to review all of these XML files during this chapter. We will do this so that you can learn the
basics of XML markup, and also to show you how user interface design, menu systems, text values,
styles and themes (global application styles), screen layout dimensions, and even your application
configuration, using the Android Manifest, can all be easily implemented using only XML markup.
We will again take a closer look at all of the basic Android application components during this
chapter, but this time, instead of doing this by looking at the Android application resource folder
structure, we will do this by looking at the AndroidManifest.xml file. We will be learning about
this Android Manifest XML definition file and its functions, structure, and its role in defining and
controlling how your application will work within the Android OS, as well as within the Google Play
e-storefront.