Udostępnij za pośrednictwem


CompoundButton.SetButtonIcon(Icon) Method

Definition

Sets the button of this CompoundButton to the specified Icon.

[Android.Runtime.Register("setButtonIcon", "(Landroid/graphics/drawable/Icon;)V", "GetSetButtonIcon_Landroid_graphics_drawable_Icon_Handler", ApiSince=31)]
public virtual void SetButtonIcon (Android.Graphics.Drawables.Icon? icon);
[<Android.Runtime.Register("setButtonIcon", "(Landroid/graphics/drawable/Icon;)V", "GetSetButtonIcon_Landroid_graphics_drawable_Icon_Handler", ApiSince=31)>]
abstract member SetButtonIcon : Android.Graphics.Drawables.Icon -> unit
override this.SetButtonIcon : Android.Graphics.Drawables.Icon -> unit

Parameters

icon
Icon

an Icon holding the desired button, or null to clear the button

Attributes

Remarks

Sets the button of this CompoundButton to the specified Icon.

Java documentation for android.widget.CompoundButton.setButtonIcon(android.graphics.drawable.Icon).

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.

Applies to