public class Canvas2DRenderingContext extends Object
Constructor and Description |
---|
Canvas2DRenderingContext(Canvas2D canvas) |
Modifier and Type | Method and Description |
---|---|
void |
restore() |
void |
save() |
void |
setFillRect(int x,
int y,
int width,
int height) |
void |
setFillStyle(Color color) |
void |
setFont(String font) |
void |
setTextAlign(TextAlign textAlign) |
void |
setTextBaseline(com.google.gwt.canvas.dom.client.Context2d.TextBaseline textBaseline) |
public Canvas2DRenderingContext(Canvas2D canvas)
public void setFont(String font)
font
- a string like "<text size>px <font family>" e.g. "12px
helvetica"public void setFillStyle(Color color)
color
- public void setTextAlign(TextAlign textAlign)
textAlign
- public void setTextBaseline(com.google.gwt.canvas.dom.client.Context2d.TextBaseline textBaseline)
textBaseline
- public void setFillRect(int x, int y, int width, int height)
x
- y
- width
- height
- public void save()
public void restore()
Copyright © 2018 Xalys. All rights reserved.