As with many programming languages, design and functionality are dealt with more or less separately. We use XML to design our layouts and Java to provide them with functionality. Here, we will see how both of these are done and will deal separately with each.
We will be using the graphical design view to construct this UI, but it is worth checking the text view from the tab at the bottom after each step, to see how the changes that we make are applied in XML.
Hello Worldproject and then the
TextViewcontrol into the middle of the screen, like so: