How to create a resizable rectangle with user touch events on Android?
问题 I want to create a rectangular shape that will be resized with the touches of the user. Below image is a good example of what i want to do: Is there any example like that? What do I need to study to implement this? Thanks in advance, 回答1: To implement a custom view, you derive a class from View :) Override onDraw() for looks, override onTouchEvent() for input processing. Note that in Android, you cannot draw on view outside onDraw() ; if you want to refresh the view, call invalidate() . You