Clears the entire canvas to rgba(0, 0, 0, 0)
.
Canvas.clearRect(float x,
float y,
float width,
float height)
Clears the specified region to rgba (0, 0, 0, 0)
.
Intersects the current clip with the specified path.
Canvas.clipRect(float x,
float y,
float width,
float height)
Intersects the current clip with the supplied rectangle.
Creates a
Canvas
with the specified display unit size.
Creates a
Canvas
at the specified scale and with the specified (pixel) width and
height.
Draws image
at the specified location (x, y)
.
Draws a scaled image at the specified location (x, y)
size (w x h)
.
Canvas.draw(Canvas.Drawable image,
float dx,
float dy,
float dw,
float dh,
float sx,
float sy,
float sw,
float sh)
Draws a subregion of a image (sw x sh) @ (sx, sy)
at the specified size
(dw x dh)
and location (dx, dy)
.
Canvas.drawArc(float cx,
float cy,
float r,
float startAngle,
float arcAngle)
Draws an arc of a circle centered at cx, cy, with radius r.
Draws image
centered at the specified location.
Canvas.drawLine(float x0,
float y0,
float x1,
float y1)
Draws a line between the two specified points.
Draws a single point at the specified location.
Draws text at the specified location.
Fills a circle at the specified center and radius.
Fills the specified path.
Canvas.fillRect(float x,
float y,
float width,
float height)
Fills the specified rectangle.
Canvas.fillRoundRect(float x,
float y,
float width,
float height,
float radius)
Fills the specified rounded rectangle.
Fills the text at the specified location.
Restores the canvas's previous state.
Rotates the current transformation matrix by the specified angle in radians.
The save and restore methods preserve and restore the state of the canvas,
but not specific paths or graphics.
Canvas.scale(float x,
float y)
Scales the current transformation matrix by the specified amount.
Set the global alpha value to be used for all painting.
Sets the Porter-Duff composite operation to be used for all painting.
Sets the color to be used for fill operations.
Sets the gradient to be used for fill operations.
Sets the pattern to be used for fill operations.
Sets the line-cap mode for strokes.
Sets the line-join mode for strokes.
Sets the miter limit for strokes.
Sets the color for strokes.
Sets the width for strokes, in pixels.
Strokes a circle at the specified center and radius.
Strokes the specified path.
Canvas.strokeRect(float x,
float y,
float width,
float height)
Strokes the specified rectangle.
Canvas.strokeRoundRect(float x,
float y,
float width,
float height,
float radius)
Strokes the specified rounded rectangle.
Strokes the text at the specified location.
Creates a canvas image large enough to accommodate this text block and renders the lines into
it.
Canvas.transform(float m11,
float m12,
float m21,
float m22,
float dx,
float dy)
Multiplies the current transformation matrix by the given matrix.
Translates the current transformation matrix by the given amount.