Button input

The button input is one of the most common type of components used in an Android project. Let's come back to our design mode and create a button on the screen:

Reverting back to Design mode from Text mode

Click on the Design button and switch back to our visual editor mode on our activity_fullscreen.xml file.

Here, we will need to do some changes to our XML file. Follow the steps as mentioned:

  1. From the Palette, scroll down and find Linear Layout(Horizontal) and drag and drop it inside the fullscreen_content_controls.
  2. In the Component Tree window below the Palette, drag and drop your TextView under your newly created LinearLayout(horizontal) ...

Get Learning Android Game Development now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.