October 2018
Intermediate to advanced
464 pages
15h 17m
English
We will create a new class for our custom component to derive from the Android View class. Our custom component could be a subclass of an existing class, such as the activity, but we will create it in a separate file to make it easier to maintain. Here are the steps:
public class CustomView extends View {
final Paint mPaint = new Paint();