Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.

  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint

5.7. Wrap-Up

In this chapter, we created the Favorite Twitter Searches app. First we designed the GUI. We introduced the ScrollView component—a ViewGroup that lets users scroll through content too large to display in the space available—and used it to display the arbitrarily large list of saved searches. Each search was associated with a Button that the user could touch to pass the search to the device’s web browser. You also learned how to create resource files by using the New Android XML File dialog. In particular, you created a colors.xml file to store color resources, a dimen.xml file to store dimensions and a second layout file that the app inflated dynamically. We discussed how to reference colors and dimensions in XML layouts and how to use predefined colors from Android’s R.color class.


  

You are currently reading a PREVIEW of this book.

                                                                                                                    

Get instant access to over $1 million worth of books and videos.

  

Start a Free 10-Day Trial


  
  • Safari Books Online
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint