How Edit Image view in android
I have Image View I want to show the Current time and date on each Image View. I don't know how to edit the Image view in android.
Hope this trick will help:
Take a textview and add your image as it's background and set it's text to current date and time whatever you want. :)
Yes you can do that using onDraw(Canvas c) which takes canvas parameter.Here is also some functions of Canvas which can help you.
You should be able to just override the OnDraw
method and you will get the canvas parameter.
http://developer.android.com/reference/android/widget/ImageView.html#onDraw(android.graphics.Canvas)
Here is an example of someone overriding in this question: Creating Custom ImageView
In order to save this to a database you will just need to save the canvas as a bitmap
精彩评论