Code example for Paint

Methods: setAntiAliassetColorsetStrokeCapsetStrokeJoinsetStrokeWidthsetStyle

0
 
        setVisibility(VISIBLE);
         
        isTransparency = false;
 
        mPaint = new Paint();
        mPaint.setAntiAlias(true);
        mPaint.setColor(0xFF66009A);
        mPaint.setStyle(Paint.Style.STROKE);
        mPaint.setStrokeJoin(Paint.Join.ROUND);
        mPaint.setStrokeCap(Paint.Cap.ROUND);
        mPaint.setStrokeWidth(2);
 
        bgColor = 0xFFFFFFFF;
         
        //setBackgroundColor(0); 
        //setZOrderOnTop(true); 
        //getHolder().setFormat(PixelFormat.TRANSLUCENT); 
         
        setFocusable(true); // make sure we get key events
Contextual code suggestions in your IDE  Get Codota for Java