Interface Canvas
Namespace: Unity.UIWidgets.ui
Syntax
public interface Canvas
Methods
clipPath(Path)
Declaration
void clipPath(Path path)
Parameters
| Type | Name | Description |
|---|---|---|
| Path | path |
clipRect(Rect)
Declaration
void clipRect(Rect rect)
Parameters
| Type | Name | Description |
|---|---|---|
| Rect | rect |
clipRRect(RRect)
Declaration
void clipRRect(RRect rrect)
Parameters
| Type | Name | Description |
|---|---|---|
| RRect | rrect |
concat(Matrix3)
Declaration
void concat(Matrix3 matrix)
Parameters
| Type | Name | Description |
|---|---|---|
| Matrix3 | matrix |
drawArc(Rect, Single, Single, Boolean, Paint)
Declaration
void drawArc(Rect rect, float startAngle, float sweepAngle, bool useCenter, Paint paint)
Parameters
| Type | Name | Description |
|---|---|---|
| Rect | rect | |
| Single | startAngle | |
| Single | sweepAngle | |
| Boolean | useCenter | |
| Paint | paint |
drawCircle(Offset, Single, Paint)
Declaration
void drawCircle(Offset c, float radius, Paint paint)
Parameters
| Type | Name | Description |
|---|---|---|
| Offset | c | |
| Single | radius | |
| Paint | paint |
drawDRRect(RRect, RRect, Paint)
Declaration
void drawDRRect(RRect outer, RRect inner, Paint paint)
Parameters
| Type | Name | Description |
|---|---|---|
| RRect | outer | |
| RRect | inner | |
| Paint | paint |
drawImage(Image, Offset, Paint)
Declaration
void drawImage(Image image, Offset offset, Paint paint)
Parameters
| Type | Name | Description |
|---|---|---|
| Image | image | |
| Offset | offset | |
| Paint | paint |
drawImageNine(Image, Rect, Rect, Paint)
Declaration
void drawImageNine(Image image, Rect center, Rect dst, Paint paint)
Parameters
| Type | Name | Description |
|---|---|---|
| Image | image | |
| Rect | center | |
| Rect | dst | |
| Paint | paint |
drawImageNine(Image, Rect, Rect, Rect, Paint)
Declaration
void drawImageNine(Image image, Rect src, Rect center, Rect dst, Paint paint)
Parameters
| Type | Name | Description |
|---|---|---|
| Image | image | |
| Rect | src | |
| Rect | center | |
| Rect | dst | |
| Paint | paint |
drawImageRect(Image, Rect, Paint)
Declaration
void drawImageRect(Image image, Rect dst, Paint paint)
Parameters
| Type | Name | Description |
|---|---|---|
| Image | image | |
| Rect | dst | |
| Paint | paint |
drawImageRect(Image, Rect, Rect, Paint)
Declaration
void drawImageRect(Image image, Rect src, Rect dst, Paint paint)
Parameters
| Type | Name | Description |
|---|---|---|
| Image | image | |
| Rect | src | |
| Rect | dst | |
| Paint | paint |
drawLine(Offset, Offset, Paint)
Declaration
void drawLine(Offset from, Offset to, Paint paint)
Parameters
| Type | Name | Description |
|---|---|---|
| Offset | from | |
| Offset | to | |
| Paint | paint |
drawOval(Rect, Paint)
Declaration
void drawOval(Rect rect, Paint paint)
Parameters
| Type | Name | Description |
|---|---|---|
| Rect | rect | |
| Paint | paint |
drawParagraph(Paragraph, Offset)
Declaration
void drawParagraph(Paragraph paragraph, Offset offset)
Parameters
| Type | Name | Description |
|---|---|---|
| Paragraph | paragraph | |
| Offset | offset |
drawPath(Path, Paint)
Declaration
void drawPath(Path path, Paint paint)
Parameters
| Type | Name | Description |
|---|---|---|
| Path | path | |
| Paint | paint |
drawPicture(Picture)
Declaration
void drawPicture(Picture picture)
Parameters
| Type | Name | Description |
|---|---|---|
| Picture | picture |
drawRect(Rect, Paint)
Declaration
void drawRect(Rect rect, Paint paint)
Parameters
| Type | Name | Description |
|---|---|---|
| Rect | rect | |
| Paint | paint |
drawRRect(RRect, Paint)
Declaration
void drawRRect(RRect rect, Paint paint)
Parameters
| Type | Name | Description |
|---|---|---|
| RRect | rect | |
| Paint | paint |
drawShadow(Path, Color, Single, Boolean)
Declaration
void drawShadow(Path path, Color color, float elevation, bool transparentOccluder)
Parameters
| Type | Name | Description |
|---|---|---|
| Path | path | |
| Color | color | |
| Single | elevation | |
| Boolean | transparentOccluder |
drawTextBlob(TextBlob, Offset, Paint)
Declaration
void drawTextBlob(TextBlob textBlob, Offset offset, Paint paint)
Parameters
| Type | Name | Description |
|---|---|---|
| TextBlob | textBlob | |
| Offset | offset | |
| Paint | paint |
flush()
Declaration
void flush()
getDevicePixelRatio()
Declaration
float getDevicePixelRatio()
Returns
| Type | Description |
|---|---|
| Single |
getSaveCount()
Declaration
int getSaveCount()
Returns
| Type | Description |
|---|---|
| Int32 |
getTotalMatrix()
Declaration
Matrix3 getTotalMatrix()
Returns
| Type | Description |
|---|---|
| Matrix3 |
reset()
Declaration
void reset()
resetMatrix()
Declaration
void resetMatrix()
restore()
Declaration
void restore()
rotate(Single, Offset)
Declaration
void rotate(float radians, Offset offset = null)
Parameters
| Type | Name | Description |
|---|---|---|
| Single | radians | |
| Offset | offset |
save()
Declaration
void save()
saveLayer(Rect, Paint)
Declaration
void saveLayer(Rect bounds, Paint paint = null)
Parameters
| Type | Name | Description |
|---|---|---|
| Rect | bounds | |
| Paint | paint |
scale(Single, Nullable<Single>)
Declaration
void scale(float sx, float? sy = default(float? ))
Parameters
| Type | Name | Description |
|---|---|---|
| Single | sx | |
| Nullable<Single> | sy |
setMatrix(Matrix3)
Declaration
void setMatrix(Matrix3 matrix)
Parameters
| Type | Name | Description |
|---|---|---|
| Matrix3 | matrix |
skew(Single, Single)
Declaration
void skew(float sx, float sy)
Parameters
| Type | Name | Description |
|---|---|---|
| Single | sx | |
| Single | sy |
translate(Single, Single)
Declaration
void translate(float dx, float dy)
Parameters
| Type | Name | Description |
|---|---|---|
| Single | dx | |
| Single | dy |