Initializer

init(_:bundle:label:)

Creates a labeled image that you can use as content for controls, with the specified label.

Declaration

init(_ name: String, bundle: Bundle? = nil, label: Text)

Parameters

name

the name of the image resource to lookup

bundle

the bundle to search for the image resource. If nil, uses the main Bundle. Defaults to nil.

label

The label associated with the image. The label is used for things like accessibility.