One Logo Pool Ball
UIKit · IOS API REFERENCE

UIAction

class · iOS 13.0+ · SDK 27.1

@MainActor class UIAction

Members (17)

static · iOS 15.0+

captureTextFromCamera

TypeScript
static captureTextFromCamera(responder: (UIResponder) & (SDKHandle), identifier?: (UIAction_Identifier) | null): Promise<UIAction>
Swift declaration
class func captureTextFromCamera(responder: any UIResponder & UIKeyInput, identifier: UIAction.Identifier?) -> Self
get · iOS 13.0+

attributes

TypeScript
get attributes(): Promise<UIMenuElement_Attributes>
Swift declaration
var attributes: UIMenuElement.Attributes { get set }
set · iOS 13.0+

attributes

TypeScript
setAttributes(value: UIMenuElement_Attributes): Promise<void>
Swift declaration
var attributes: UIMenuElement.Attributes { get set }
get · iOS 13.0+

discoverabilityTitle

TypeScript
get discoverabilityTitle(): Promise<(string) | null>
Swift declaration
var discoverabilityTitle: String? { get set }
set · iOS 13.0+

discoverabilityTitle

TypeScript
setDiscoverabilityTitle(value?: (string) | null): Promise<void>
Swift declaration
var discoverabilityTitle: String? { get set }
get · iOS 13.0+

identifier

TypeScript
get identifier(): Promise<UIAction_Identifier>
Swift declaration
var identifier: UIAction.Identifier { get }
get · iOS 13.0+

image

TypeScript
get image(): Promise<(UIImage) | null>
Swift declaration
@NSCopying var image: UIImage? { get set }
set · iOS 13.0+

image

TypeScript
setImage(value?: (UIImage) | null): Promise<void>
Swift declaration
@NSCopying var image: UIImage? { get set }
get · iOS 14.0+

sender

TypeScript
get sender(): Promise<(unknown) | null>
Swift declaration
var sender: Any? { get }
get · iOS 13.0+

state

TypeScript
get state(): Promise<UIMenuElement_State>
Swift declaration
var state: UIMenuElement.State { get set }
set · iOS 13.0+

state

TypeScript
setState(value: UIMenuElement_State): Promise<void>
Swift declaration
var state: UIMenuElement.State { get set }
get · iOS 13.0+

title

TypeScript
get title(): Promise<string>
Swift declaration
var title: String { get set }
set · iOS 13.0+

title

TypeScript
setTitle(value: string): Promise<void>
Swift declaration
var title: String { get set }
init · iOS 13.0+

init

TypeScript
static initTitleImageIdentifierDiscoverabilityTitleAttributesStateHandler(title: string, image: (UIImage) | null, identifier: (UIAction_Identifier) | null, discoverabilityTitle: (string) | null, attributes: UIMenuElement_Attributes, state: UIMenuElement_State, handler: ((arg0: UIAction) => void)): Promise<UIAction>
Swift declaration
@MainActor @preconcurrency convenience init(title: String = "", image: UIImage? = nil, identifier: UIAction.Identifier? = nil, discoverabilityTitle: String? = nil, attributes: UIMenuElement.Attributes = [], state: UIMenuElement.State = .off, handler: @escaping UIActionHandler)
init · iOS 15.0+

init

TypeScript
static initTitleSubtitleImageIdentifierDiscoverabilityTitleAttributesStateHandler(title: string, subtitle: (string) | null, image: (UIImage) | null, identifier: (UIAction_Identifier) | null, discoverabilityTitle: (string) | null, attributes: UIMenuElement_Attributes, state: UIMenuElement_State, handler: ((arg0: UIAction) => void)): Promise<UIAction>
Swift declaration
@MainActor @preconcurrency convenience init(title: String = "", subtitle: String? = nil, image: UIImage? = nil, identifier: UIAction.Identifier? = nil, discoverabilityTitle: String? = nil, attributes: UIMenuElement.Attributes = [], state: UIMenuElement.State = .off, handler: @escaping UIActionHandler)
init · iOS 27.0+

init

TypeScript
static initTitleSubtitleImageSelectedImagePreferredImageVisibilityIdentifierDiscoverabilityTitleAttributesStateHandler(title: string, subtitle: (string) | null, image: (UIImage) | null, selectedImage: (UIImage) | null, preferredImageVisibility: UIMenuElement_ImageVisibility, identifier: (UIAction_Identifier) | null, discoverabilityTitle: (string) | null, attributes: UIMenuElement_Attributes, state: UIMenuElement_State, handler: ((arg0: UIAction) => void)): Promise<UIAction>
Swift declaration
@MainActor @preconcurrency convenience init(title: String = "", subtitle: String? = nil, image: UIImage? = nil, selectedImage: UIImage? = nil, preferredImageVisibility: UIMenuElement.ImageVisibility = .automatic, identifier: UIAction.Identifier? = nil, discoverabilityTitle: String? = nil, attributes: UIMenuElement.Attributes = [], state: UIMenuElement.State = .off, handler: @escaping UIActionHandler)
init · iOS 17.0+

init

TypeScript
static initTitleSubtitleImageSelectedImageIdentifierDiscoverabilityTitleAttributesStateHandler(title: string, subtitle: (string) | null, image: (UIImage) | null, selectedImage: (UIImage) | null, identifier: (UIAction_Identifier) | null, discoverabilityTitle: (string) | null, attributes: UIMenuElement_Attributes, state: UIMenuElement_State, handler: ((arg0: UIAction) => void)): Promise<UIAction>
Swift declaration
@MainActor @preconcurrency convenience init(title: String = "", subtitle: String? = nil, image: UIImage? = nil, selectedImage: UIImage? = nil, identifier: UIAction.Identifier? = nil, discoverabilityTitle: String? = nil, attributes: UIMenuElement.Attributes = [], state: UIMenuElement.State = .off, handler: @escaping UIActionHandler)

Skipped declarations

1 declarations were excluded from these bindings. Each reason comes from the generator or the iOS SDK compiler.

UIAction.init()

inherited init: cannot prove legal (class declares 4 custom initializers)

All UIKit types →