Hello Romain! I put a background image in view, so I can not draw with the background color.
On Wed, May 29, 2013 at 1:53 AM, Romain Guy <[email protected]> wrote: > Erase is working as intended here. You are erasing the window's Canvas, > which is shared by all the Views. If you want to erase to transparent you > should make that View use a drawing cache (setDrawingCacheEnabled()) or a > layer (setLayerType()) but this will come at a cost performance-wise. > Another solution is to simply draw with your background color. > > > On Tue, May 28, 2013 at 8:43 PM, Tiago Braga <[email protected]>wrote: > >> Hello! >> >> I am starting the studies, and decide to make a little program to draw on a >> white canvas. >> >> I rode one example of android called "FingerPaint" and I noticed >> something: >> When I select the option "Erase", it uses the following method to clean >> up what is on the screen: >> >> mPaint.setXfermode (new PorterDuffXfermode (PorterDuff.Mode.CLEAR)); >> >> It cleans up really, but while you're dragging the screen to clear, is >> appearing black lines. >> >> How do I solve this? >> >> -- >> Atenciosamente, >> Tiago Braga Machado >> >> -- >> -- >> You received this message because you are subscribed to the Google >> Groups "Android Developers" group. >> To post to this group, send email to [email protected] >> To unsubscribe from this group, send email to >> [email protected] >> For more options, visit this group at >> http://groups.google.com/group/android-developers?hl=en >> --- >> You received this message because you are subscribed to the Google Groups >> "Android Developers" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected]. >> For more options, visit https://groups.google.com/groups/opt_out. >> >> >> > > > > -- > Romain Guy > Android framework engineer > [email protected] > > -- > -- > You received this message because you are subscribed to the Google > Groups "Android Developers" group. > To post to this group, send email to [email protected] > To unsubscribe from this group, send email to > [email protected] > For more options, visit this group at > http://groups.google.com/group/android-developers?hl=en > --- > You received this message because you are subscribed to the Google Groups > "Android Developers" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/groups/opt_out. > > > -- Atenciosamente, Tiago Braga Machado -- -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en --- You received this message because you are subscribed to the Google Groups "Android Developers" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.

