Szerkesztés

Megosztás a következőn keresztül:


UIBarButtonItem.SetBackgroundImage Method

Definition

Overloads

SetBackgroundImage(UIImage, UIControlState, UIBarMetrics)

Allows the background image to be set for the button for a given control state and bar metrics.

SetBackgroundImage(UIImage, UIControlState, UIBarButtonItemStyle, UIBarMetrics)

Specifies the UIImage used as a background.

SetBackgroundImage(UIImage, UIControlState, UIBarMetrics)

Allows the background image to be set for the button for a given control state and bar metrics.

[Foundation.Export("setBackgroundImage:forState:barMetrics:")]
public virtual void SetBackgroundImage (UIKit.UIImage backgroundImage, UIKit.UIControlState state, UIKit.UIBarMetrics barMetrics);
abstract member SetBackgroundImage : UIKit.UIImage * UIKit.UIControlState * UIKit.UIBarMetrics -> unit
override this.SetBackgroundImage : UIKit.UIImage * UIKit.UIControlState * UIKit.UIBarMetrics -> unit

Parameters

backgroundImage
UIImage

The background image to use for the button.

This parameter can be null.

state
UIControlState

The control state to apply the background image for.

barMetrics
UIBarMetrics

The bar metrics to apply the background image for.

Attributes

Remarks

This member participates in the UIAppearance styling system. See the Appearance property and the AppearanceWhenContainedIn(Type[]) method.

Applies to

SetBackgroundImage(UIImage, UIControlState, UIBarButtonItemStyle, UIBarMetrics)

Specifies the UIImage used as a background.

[Foundation.Export("setBackgroundImage:forState:style:barMetrics:")]
[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 6, 0, ObjCRuntime.PlatformArchitecture.All, null)]
public virtual void SetBackgroundImage (UIKit.UIImage backgroundImage, UIKit.UIControlState state, UIKit.UIBarButtonItemStyle style, UIKit.UIBarMetrics barMetrics);
abstract member SetBackgroundImage : UIKit.UIImage * UIKit.UIControlState * UIKit.UIBarButtonItemStyle * UIKit.UIBarMetrics -> unit
override this.SetBackgroundImage : UIKit.UIImage * UIKit.UIControlState * UIKit.UIBarButtonItemStyle * UIKit.UIBarMetrics -> unit

Parameters

backgroundImage
UIImage

Background image to use for the UIBarButtonItem.

This parameter can be null.

barMetrics
UIBarMetrics
Attributes

Remarks

This member participates in the UIAppearance styling system. See the Appearance property and the AppearanceWhenContainedIn(Type[]) method.

Applies to