iOS Guides | Samples

MonoTouch.UIKit.UIControl Class

The base class for controls in MonoTouch.UIKit.

See Also: UIControl

Syntax

[MonoTouch.Foundation.Register("UIControl", true)]
public class UIControl : UIView

Remarks

Related content

Requirements

Namespace: MonoTouch.UIKit
Assembly: monotouch (in monotouch.dll)
Assembly Versions: 0.0.0.0

The members of MonoTouch.UIKit.UIControl are listed below.

See Also: UIView

Public Constructors

Default constructor that initializes a new instance of this class with no parameters.
A constructor that initializes the object from the data stored in the unarchiver object.
Constructor to call on derived classes to skip initialization and merely allocate the object.
Initializes the UIControl with the specified frame.
A constructor used when creating managed representations of unmanaged objects; Called by the runtime.

Public Properties

[read-only]
AllControlEventsUIControlEvent. The control events associated with this UIControl.
[read-only]
AllTargetsNSSet. The target objects associated with this UIControl.
[read-only]
static
AppearanceUIControl+UIControlAppearance. Strongly-typed property that returns the UIAppearance class for this class.
[read-only]
override
ClassHandleIntPtr. The handle for this class.
EnabledBoolean. Whether this UIControl is enabled.
HighlightedBoolean. Whether this UIControl is highlighted.
HorizontalAlignmentUIControlContentHorizontalAlignment. The horizontal alignment of this UIControl's content.
SelectedBoolean. Whether this UIControl is selected.
[read-only]
StateUIControlState. A bitmask that indicates the state of this UIControl. Read-only.
[read-only]
TouchInsideBoolean. Whether a touch is inside this UIControl. Read-only.
[read-only]
TrackingBoolean. Whether this UIControl is tracking touches related to an event. Read-only.
VerticalAlignmentUIControlContentVerticalAlignment. The vertical alignment of this UIControl's content.

Public Methods

AddTarget(EventHandler, UIControlEvent)
Adds an event handler for the specified set of events.
AddTarget(NSObject, Selector, UIControlEvent)
Adds a target and control event(s) to this UIControl's internal dispatch table.
static
AppearanceWhenContainedIn(params Type[]) : UIControl+UIControlAppearance
Returns a strongly typed UIAppearance for instances of this class when the view is hosted in the specified hierarchy.
BeginTracking(UITouch, UIEvent) : Boolean
Indicates that a touch related to the specified event has entered the UIControl's bounds.
CancelTracking(UIEvent)
Stops tracking related to the specified event.
ContinueTracking(UITouch, UIEvent) : Boolean
Called repeatedly as the UIControl tracks a touch within its bounds, related to the specified event.|Called repeatedly as the UIControl tracks a touch within its bounds, related to the givespecified event.
EndTracking(UITouch, UIEvent)
Indicates that the last touch for the given event has completed, indicating that tracking should stop.
GetActions(NSObject, UIControlEvent) : String[]
The actions associated with a target and control event.
static
GetAppearance(UITraitCollection) : UIControl+UIControlAppearance
Returns an appearance proxy for the specified traits.
static
GetAppearance(UITraitCollection, params Type[]) : UIControl+UIControlAppearance
Returns an appearance proxy for the specified traits when found in the containers containment hierarchy.
static
GetAppearance<T>() : UIControl+UIControlAppearance
Obtains the appearance proxy UIControlAppearance for the subclass of UIControl.
static
GetAppearance<T>(UITraitCollection) : UIControl+UIControlAppearance
Obtains the appearance proxy UIControlAppearance for the subclass of UIControl.
static
GetAppearance<T>(UITraitCollection, params Type[]) : UIControl+UIControlAppearance
Obtains the appearance proxy UIControlAppearance for the subclass of UIControl that has the specified trait collection when the view is hosted in the specified hierarchy.
RemoveTarget(EventHandler, UIControlEvent)
Removes a previously installed event handler for the specified event list.
RemoveTarget(NSObject, Selector, UIControlEvent)
Removes a target and action for a particular event or events.
SendAction(Selector, NSObject, UIEvent)
Indicates that an event has occurred and sends an action message to the application for dispatch to a target.
SendActionForControlEvents(UIControlEvent)
Sends action messages for the specified control events.

Public Events

AllEditingEventsRaised on any editing events produced.
AllEventsRaised for any event produced.
AllTouchEventsRaised for any touch event produced.
EditingChangedThe component changed.
EditingDidBeginRaised when editing has started.
EditingDidEndRaised when editing ended.
EditingDidEndOnExitRaised on didEndOnexit
PrimaryActionTriggered
TouchCancelThe touch event has been canceled.
TouchDownRaised when the user touches the control.
TouchDownRepeatRaised when the user double taps the control.
TouchDragEnterRaised on TouchDragEnter events.
TouchDragExitRaised on TouchDragExit events.
TouchDragInsideRaised oN TouchDragInside events.
TouchDragOutsideRaised on TouchDragOutside events.
TouchUpInsideRaised on TouchUpInside events.
TouchUpOutsideRaised on TouchUpOutside events.
ValueChangedThe value has changed.