AdaptiveIconDrawable.Draw(Canvas) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Draws the icon layers through the icon mask.
[Android.Runtime.Register("draw", "(Landroid/graphics/Canvas;)V", "GetDraw_Landroid_graphics_Canvas_Handler", ApiSince=26)]
public override void Draw(Android.Graphics.Canvas? canvas);
[<Android.Runtime.Register("draw", "(Landroid/graphics/Canvas;)V", "GetDraw_Landroid_graphics_Canvas_Handler", ApiSince=26)>]
override this.Draw : Android.Graphics.Canvas -> unit
Parameters
- canvas
- Canvas
The canvas to draw into. This value cannot be null.
- Attributes
Remarks
On Android 8.0 and 8.1 (API levels 26 and 27), alpha is passed to each layer, and the layers are drawn over an opaque black background before the mask is applied. On Android 9 (API level 28) and later, alpha is applied to the masked icon. The effect of a color filter depends on each layer's implementation.
Android reference for android.graphics.drawable.AdaptiveIconDrawable.draw.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.