ShapeDrawable.OnDraw(Shape, Canvas, Paint) 方法

定义

在画布设置为绘制形状(0,0)后,从绘图对象的 draw() 方法调用。

[Android.Runtime.Register("onDraw", "(Landroid/graphics/drawable/shapes/Shape;Landroid/graphics/Canvas;Landroid/graphics/Paint;)V", "GetOnDraw_Landroid_graphics_drawable_shapes_Shape_Landroid_graphics_Canvas_Landroid_graphics_Paint_Handler")]
protected virtual void OnDraw (Android.Graphics.Drawables.Shapes.Shape? shape, Android.Graphics.Canvas? canvas, Android.Graphics.Paint? paint);
[<Android.Runtime.Register("onDraw", "(Landroid/graphics/drawable/shapes/Shape;Landroid/graphics/Canvas;Landroid/graphics/Paint;)V", "GetOnDraw_Landroid_graphics_drawable_shapes_Shape_Landroid_graphics_Canvas_Landroid_graphics_Paint_Handler")>]
abstract member OnDraw : Android.Graphics.Drawables.Shapes.Shape * Android.Graphics.Canvas * Android.Graphics.Paint -> unit
override this.OnDraw : Android.Graphics.Drawables.Shapes.Shape * Android.Graphics.Canvas * Android.Graphics.Paint -> unit

参数

shape
Shape
canvas
Canvas
paint
Paint
属性

注解

在画布设置为绘制形状(0,0)后,从绘图对象的 draw() 方法调用。 子类可以替代特殊效果,例如多层、串流等。

适用于 . 的 android.graphics.drawable.ShapeDrawable.onDraw(android.graphics.drawable.shapes.Shape, android.graphics.Canvas, android.graphics.Paint)Java 文档

本页的某些部分是根据 Android 开放源代码项目创建和共享的工作进行的修改,并根据 Creative Commons 2.5 属性许可证中所述的术语使用。

适用于