March 2016
Intermediate to advanced
428 pages
9h 2m
English
As we have seen in previous recipes, the Android SDK provides a wide range of components. But what happens when you can't find a prebuilt component that fits your unique needs? You can always create your own!
In this recipe, we will walk through creating a custom component that derives from the View class, just like the built-in widgets. Here's a high-level overview:
onMeasure(), and the default implementation returns a size of 100 x 100.onDraw(), and the default implementation draws nothing.While overriding onMeasure()
and onDraw()
is not strictly ...
Read now
Unlock full access