Code example for Region

Methods: setPath

0
     * Updates the internal data required to draw. 
     */ 
    private void update() { 
        RectF rect = new RectF();
        mPath.computeBounds(rect, false);
        mRegion = new Region((int)rect.left, (int)rect.top, (int)rect.right, (int)rect.bottom);
        mRegion.setPath(mPath, mRegion);
    } 
 
    /** 
     * {@inheritDoc}  
     */ 
    @Override 
    public boolean equals(Object o) {
        if (o instanceof PathShape) {
            PathShape pathShape = (PathShape)o;
            Region region = new Region(this.mRegion);
            if (! region.op(pathShape.mRegion, Op.XOR)) {
                return true; 
            } 
Stop searching for code, let great code find you!  Add Codota to your java IDE