You are previewing Android User Interface Development.
O'Reilly logo
Android User Interface Development

Book Description

Quickly design and develop compelling user interfaces for your Android applications

  • Leverage the Android platform's flexibility and power to design impactful user-interfaces

  • Build compelling, user-friendly applications that will look great on any Android device

  • Make your application stand out from the rest with styles and themes

  • A practical Beginner's Guide to take you step-by-step through the process of developing user interfaces to get your applications noticed!

  • In Detail

    There are over 30,000 applications for Android that have been downloaded over a million times already. What makes yours any different? Building a compelling user-interface that people understand and enjoy is vital for the survival of a new application in an environment where look and feel may be the only thing between a user purchasing your application; or deleting it forever.

    Working through examples, code-snippets, and screenshots this book introduces the fundamentals of good user-interface design from a developer's point of view. This book will put you above the rest by showing you how to build striking user interfaces to grasp your app users' attention enough to make them shell out some bucks to buy your application.

    The Android User Interface Development Beginner's Guide will tell you everything you need to know to style your applications from bottom up. Given the importance of user-interface design on a touch-screen device, this book aims to equip its reader with the knowledge required to build killer Android applications. Starting simply, and keeping things easy, this book will take you on a step-by-step journey to understanding the principals of good user-interface design, and how to implement the best user interfaces on an Android mobile device. It aims at building design understanding on a chapter-by-chapter basis, while introducing platform knowledge through examples.

    A practical definitive guide for developers who want to design and develop attractive Android user-interfaces

    Table of Contents

    1. Android User Interface Development Beginner's Guide
      1. Android User Interface Development Beginner's Guide
      2. Credits
      3. About the Author
      4. About the Reviewer
      5. www.PacktPub.com
        1. Support files, eBooks, discount offers and more
          1. Why Subscribe?
          2. Free Access for Packt account holders
      6. Preface
        1. New challenges
          1. The rule of finger
          2. The magic touch
          3. A smaller view on the world
        2. Classic user interface principals
          1. Consistency
            1. Recycling your interface
          2. Simplicity
            1. The Zen approach
            2. Android's hidden menu
          3. Feedback
            1. Location and navigation
            2. The road to recovery
        3. The Android way
        4. What this book covers
        5. What you need for this book
        6. Who this book is for
        7. Conventions
        8. Time for action - heading
          1. What just happened?
          2. Pop quiz - heading
          3. Have a go hero - heading
        9. Reader feedback
        10. Customer support
          1. Errata
          2. Piracy
          3. Questions
      7. 1. Developing a Simple Activity
        1. Developing our first example
        2. Creating the project structure
        3. Time for action - setting up the Android SDK
          1. What just happened?
        4. Time for action - starting a new project
          1. What just happened
          2. Examining the Android project layout
        5. Time for action - running the example project
          1. What just happened?
        6. The screen layout
          1. The layout XML file
            1. Resource selection qualifiers
        7. Time for action - setting up the question activity
          1. What just happened?
        8. Populating a View and a ViewGroup
        9. Time for action - asking a question
          1. What just happened
        10. Time for action - adding a space for answers
          1. What just happened?
        11. Time for action - adding more buttons
          1. What just happened
          2. Defining common dimensions
          3. Have a go hero - improve the styling
        12. Limitations of the layout XML format
          1. Pop quiz -
        13. Populating the QuestionActivity
        14. Time for action - writing more Java code
          1. What just happened
        15. Dynamically creating widgets
        16. Time for action - putting the questions on the screen
          1. What just happened?
        17. Handling events in Android
          1. Pop quiz -
        18. Summary
      8. 2. Presenting Data for Views
        1. Listing and selecting data
          1. ListView choice modes
            1. No selection mode CHOICE_MODE_NONE
            2. Single selection mode CHOICE_MODE_SINGLE
            3. Multiple selection mode CHOICE_MODE_MULTIPLE
          2. Adding header and footer widgets
          3. Creating a simple ListView
        2. Time for action - creating a fast food menu
          1. What just happened
          2. Styling the standard ListAdapters
            1. Defining standard dimensions
        3. Time for action - improving the restaurant list
          1. What just happened
          2. Have a go hero - developing a multiple-choice question application
          3. Creating custom adapters
            1. Creating a menu for The Burger Place
              1. The Burger class
        4. Time for action - creating a Burger item layout
          1. What just happened?
        5. Time for action - presenting Burger objects
          1. What just happened?
          2. Creating TheBurgerPlaceActivity class
        6. Time for action - implementing TheBurgerPlaceActivity
          1. What just happened?
          2. Registering and starting TheBurgerPlaceActivity
          3. Pop quiz -
        7. Using the ExpandableListView class
          1. Creating ExpandableListAdapter implementations
          2. Have a go hero - ordering customized pizzas
        8. Using the GridView class
        9. Time for action - creating the fruit icon
          1. What just happened?
          2. Displaying icons in a GridView
        10. Time for action - building the fruit menu
          1. What just happened?
        11. Time for action - creating the FourBucketsActivity
          1. What just happened?
          2. Have a go hero - Sam's Sushi
        12. Summary
      9. 3. Developing with Specialized Android Widgets
        1. Creating a restaurant review application
        2. Time for action - creating the robotic review project structure
          1. What just happened?
        3. Building a TabActivity
          1. Creating tab icons
          2. Android tabs and icons
        4. Implementing the ReviewActivity
        5. Time for action - writing the ReviewActivity class
          1. What just happened?
        6. Time for action - creating the Review layout
          1. What just happened
          2. Working with switcher classes
        7. Time for action - turning on the TextSwitcher
          1. What just happened?
        8. Creating a simple photo gallery
        9. Time for action - building the Photos tab
          1. What just happened?
          2. Creating a thumbnail widget
          3. Implementing a GalleryAdapter
        10. Time for action - the GalleryAdapter
          1. What just happened
        11. Time for action - making the gallery work
          1. What just happened?
          2. Pop quiz -
          3. Have a go hero - animations and external sources
        12. Building the reservation tab
        13. Time for action - implementing the reservation layout
          1. What just happened?
        14. Time for action - initializing the reservation tab
          1. What just happened?
        15. Time for action - listening to the SeekBar
          1. What just happened?
        16. Time for action - selecting date and time
          1. What just happened
        17. Creating complex layouts with Include, Merge, and ViewStubs
          1. Using Include tags
          2. Merging layouts
          3. Using the ViewStub class
          4. Have a go hero - separate the tabs
        18. Summary
      10. 4. Leveraging Activities and Intents
        1. Exploring the Activity class
          1. Using Bundle objects
        2. Time for action - building an example game: "guess my number"
          1. What just happened
        3. Creating and consuming intents
          1. Defining Intent actions
          2. Passing data in an Intent
          3. Adding extra data to an Intent
          4. Have a go hero - generic questions and answers
        4. Using advanced Intent features
          1. Getting data back from an Intent
          2. Pop quiz -
        5. Time for action - viewing phone book contacts
          1. What just happened
        6. Summary
      11. 5. Developing Non-linear Layouts
        1. Time for action - creating a layouts example project
          1. What just happened?
        2. FrameLayout
          1. Common uses
        3. Time for action - developing a FrameLayout example
          1. What just happened?
        4. Table Layout
          1. Common uses
          2. Using TableLayout for a memory game
        5. Time for action - developing a simple memory game
          1. What just happened
          2. Have a go hero
        6. AbsoluteLayout/Custom Layouts
          1. Developing your own Layouts
        7. Time for action - creating a custom layout
          1. What just happened?
          2. Using the CircleLayout
        8. Time for action - finishing the CircleLayout example
          1. What just happened?
          2. Pop quiz -
        9. RelativeLayout
          1. Common uses
          2. Integrating the RelativeLayout
        10. Time for action - creating a contact editor
          1. What just happened
        11. Time for action - integration with the layout example
          1. What just happened?
        12. SlidingDrawer
          1. Common uses
          2. Creating a SlidingDrawer example
        13. Time for action - creating a SlidingDrawer
          1. What just happened?
        14. Time for action - sliding drawer integration
          1. What just happened?
        15. Summary
      12. 6. Validating and Handling Input Data
        1. Dealing with undesirable input
          1. Correctly labeling input
          2. Signaling undesirable input
          3. Recovering from undesirable input
          4. Giving users direct feedback
        2. Avoiding invalid input entirely
          1. Capturing date and time
          2. Using spinners and ListView for selection
            1. Changing the data set
            2. Disabling selections
          3. Capturing text input
          4. Autocompleting text input
          5. Pop quiz -
        3. Building activities for results
        4. Generic filtering search Activity
        5. Time for action - creating the ListItemSelectionActivity
          1. What just happened?
        6. Time for action - creating an ArrayAdapter
          1. What just happened?
        7. Time for action - creating the CursorAdapter
          1. What just happened?
        8. Time for action - setting up the ListView
          1. What just happened?
        9. Time for action - filtering the list
          1. What just happened?
        10. Time for action - returning the selection
          1. What just happened?
          2. Using the ListItemSelectionActivity
          3. Have a go hero!
        11. Summary
      13. 7. Animating Widgets and Layouts
        1. Using standard Android animations
        2. Time for action - animating a news feed
          1. What just happened?
        3. Using flipper and switcher widgets
          1. Using the ImageSwitcher and TextSwitcher implementations
          2. Have a go hero - populating the TextSwitcher
          3. Animating layout widgets
        4. Time for action - animating a GridView
          1. What just happened?
          2. Creating Custom Animations
        5. Time for action - writing a custom animation
          1. What just happened?
        6. Time for action - making a Button vanish
          1. What just happened?
        7. Summary
      14. 8. Designing Content-centric Activities
        1. Considering design options when displaying content on an Android device
          1. Considering user behavior
            1. Drawing user attention
        2. Displaying content with the WebView class
          1. Using a WebView object
        3. Time for action - creating a recipe viewer application
          1. What just happened?
          2. Have a go hero - improving the look of the recipe viewer
          3. Taking WebView further
          4. Pop quiz -
        4. Creating relative layouts for content display
          1. Taking full advantage of RelativeLayout
          2. Considering Android layout constraints
          3. Styling TextView objects
          4. Pop quiz -
        5. Time for action - developing specialized content views
          1. What just happened?
        6. Developing an online music store
          1. Designing the music store
          2. Developing the music store
        7. Time for action - building a track item
          1. What just happened
        8. Time for action - developing the main user interface layout
          1. What just happened?
        9. Time for action - developing the main user interface Java code
          1. What just happened?
          2. Have a go hero - updating the total price
        10. Summary
      15. 9. Styling Android Applications
        1. Working with style resources
        2. Using shape resources
          1. How shapes behave
            1. Rendering lines
        3. Time for action - drawing a broken line
          1. What just happened?
          2. Rendering rectangles
        4. Time for action - creating a rounded border
          1. What just happened?
          2. Rendering ovals
        5. Time for action - applying a gradient to an oval shape
          1. What just happened?
          2. Rendering rings
        6. Time for action - rendering a spinner ring
          1. What just happened
          2. Defining layers
        7. Stretching using nine-patch images
          1. Creating nine-patch images
        8. Using bitmap images in Android
          1. Handling different screen sizes
          2. Handling different screen densities
        9. Handling configuration changes
          1. Providing landscape layouts
          2. Providing text input on a landscape layout
          3. Altering screen content
        10. Summary
      16. 10. Building an Application Theme
        1. Creating a basic calculator layout
          1. Pop quiz -
          2. Designing a standard calculator
        2. Time for action - building the standard calculator
          1. What just happened?
        3. Building the calculator styling
          1. Pop quiz -
        4. Time for action - creating the button images
          1. What just happened?
        5. Time for action - styling the calculator buttons
          1. What just happened?
        6. Time for action - styling the display
          1. What just happened?
          2. Have a go hero - Adding calculator logic
          3. Pop quiz -
        7. Scientific landscape layout
          1. Defining string resources for the scientific layout
          2. Styling the scientific layout
          3. Building the scientific layout
        8. Time for action - coding the scientific layout
          1. What just happened?
          2. Have a go hero - using include in existing layouts
          3. Handling the Activity restart
          4. Have a go hero - implementing the scientific calculation logic
        9. Supporting hardware keyboards
        10. Adding in display animations
        11. Time for action - animating the display
          1. What just happened?
          2. Have a go hero - rounding off
        12. Summary
      17. A. Pop quiz - answers
        1. Chapter 1
          1. Layouts as XML fles
          2. Populating an activity
        2. Chapter 2
          1. List views and adapters
        3. Chapter 3
          1. Gallery objects and ImageViews
        4. Chapter 4
          1. Intents & Activities
        5. Chapter 5.
          1. Custom layouts
        6. Chapter 6
          1. Text input
        7. Chapter 8
          1. The WebView widget
          2. WebView versus native layouts
        8. Chapter 10
          1. Layout resources
          2. Nine-Patch Images
          3. Android resources