FAQ

  1. We know how to animate widgets now, but what about shapes or images that I create myself?

    ImageView can hold any image you like. Just add the image to the drawable folder and then set the appropriate src property on the ImageView. You can then animate whatever image is being shown in the ImageView widget.

  2. What if I want more flexibility than this, more like a drawing app or even a game?

    To implement this kind of functionality, you will need to learn another general computing concept (threads) as well as some more Android classes (such as Paint, Canvas, and SurfaceView). You will learn how to draw anything from a single pixel to shapes, and then how to move them around the screen in Chapter 28, Threads, Touches, Drawing, and a Simple Game.

Get Android Programming for Beginners now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.