Chapter 11. Working with the Canvas and Advanced Drawing
Before diving into building completely custom views, it’s a good idea to understand how to draw to the screen in Android. Drawing includes images, text, custom shapes, and more. Once you understand the basics, it’s time to use color filters, shaders, and other advanced techniques for drawing anything you want.
Creating Custom Drawables
Android’s Drawable
class is a great abstraction for anything that can be drawn to the screen. In some ways it is like a view, but it is much easier to understand and work with for a variety of uses. By extending Drawable
to create custom effects, you can easily add those effects to almost any view by setting the drawable as the background. Plus, virtually ...
Get Android User Interface Design: Implementing Material Design for Developers, Second Edition 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.