Titanium.UI.Tab
> Titanium.UI.Tab

A tab instance for a TabGroup.

A TabGroup tab instance. Each tab includes a button and one or more windows, which holds the "contents" of the tab. Users can select a tab by clicking on the tab button.

Use the Titanium.UI.createTab method or <Tab> Alloy element to create a tab.

Use TabGroup.setActiveTab to switch between tabs in a tab group. The Titanium.UI.currentTab property provides a global reference to the currently active tab.

The behavior of tabs and tab groups follows the platform's native navigation style, which varies significantly between platforms.

iOS Platform Implementation Notes

On iOS, the tab maintains a stack of windows. Windows on top of the stack can partially or totally obscure windows lower in the stack. Calling open opens a new window on top of the window stack. When a window is closed, either by the user or by code, the window is removed from the stack, making the previous window visible. The root tab window cannot be removed.

On iOS the tab controls are generally kept on screen to allow a user to navigate inside the app. Tab controls are hidden when the user is performing a modal task (for example, composing a message). In this case, the app should provide a button in the navigation bar to return to the previous screen. On iOS, the window should also be opened as modal. On iOS, The tab controls can also be hidden by opening the new window with tabBarHidden set to true.

When closing a tab window in iOS, you should always use the Tab.close method to ensure that the tab group maintains its navigation state.

Android Platform Implementation Notes

On Android, the tab does not maintain a stack of windows. Calling open opens a new, heavyweight window, which by default covers the tab group entirely. This seems quite different from the iOS model, but it is the standard model for Android applications. Users can use the Back button to close the window and return to the tab group.

On Android, tab windows can be closed using either Tab.close or Window.close. Since no window stack is maintained, only a single window opened using Tab.open can be closed using Tab.close.

As on iOS, the root tab window cannot be closed.

Examples

Simple Tab Example

In this example, we create a simple tab and add it to a tab group.

var window = Ti.UI.createWindow({
    title: 'My Tab'
});

var tab = Ti.UI.createTab({
    window: window,
    title: 'My Tab',
    icon: 'myicon.png'
});

tabGroup.addTab(tab);

Alloy XML Markup

Previous example an an Alloy view.

<Alloy>
    <TabGroup id="tabGroup">
        <Tab id="tab" title="My Tab" icon="myicon.png">
            <Window id="window" title="My Tab" />
        </Tab>
     </TabGroup>
</Alloy>
  • 0.8
  • 0.8
  • 0.8
Defined By

Properties

Titanium.UI.Tab
active : Boolean

true if this tab is active, false if it is not.

true if this tab is active, false if it is not.

The tab can be activated by setting the property, but since this property is platform-specific, using TabGroup.setActiveTab is recommended instead.

  • 0.8
  • 0.8
Titanium.UI.Tab
: String
Icon URL for this tab when active. ...

Icon URL for this tab when active.

Requires: iOS 5.0 and later

iOS 5.0 and later only.

If unspecified, iOS uses a tint color to indicate the active tab. See icon for more information.

If the icon provided is larger than [30 pixels (60 pixels in the retina variant)] (https://developer.apple.com/library/ios/#documentation/UserExperience/Conceptual/MobileHIG/IconsImages/IconsImages.html), this image will be scaled to fit.

On iOS prior to 5.0, the default tint color is always used and this property remains unset.

  • 3.1.0
  • 3.1.0
Titanium.UI.Tab
: Boolean
Defines if the active icon property of the tab must be used as a mask. ...

Defines if the active icon property of the tab must be used as a mask. This property is applicable on iOS 7 and greater.

Requires: iOS 7.0 and later

This is the equivalent of the iconIsMask property, but for the active icon. When this is true, the active icon is tinted with the color specified in tabsTintColor. When this is false the image is rendered as is, though the title of the tab is still tinted.

Default: true

  • 3.1.3
  • 3.1.3
Titanium.UI.Tab
: String
Defines the color of the title of tab when it's active. ...

Defines the color of the title of tab when it's active.

Requires: iOS 5.0 and later

The color of the title of the tab when it's active. If not defined, it will use the default tint color.

  • 4.1.0
  • 4.1.0
apiName : Stringreadonly

The name of the API that this proxy corresponds to.

The name of the API that this proxy corresponds to.

The value of this property is the fully qualified name of the API. For example, Button returns Ti.UI.Button.

  • 3.2.0
  • 3.2.0
  • 3.2.0
Titanium.UI.Tab
: String
Sets the color of the tab when it is inactive. ...

Sets the color of the tab when it is inactive.

For information about color values, see the "Colors" section of Titanium.UI.

Default: Transparent

  • 3.0.0

Overrides: Titanium.UI.View.backgroundColor

Disabled background color of the view, as a color name or hex triplet. ...

Disabled background color of the view, as a color name or hex triplet.

For information about color values, see the "Colors" section of Titanium.UI.

Default: Same as the normal background color of this view.

  • 0.9
Disabled background image for the view, specified as a local file path or URL. ...

Disabled background image for the view, specified as a local file path or URL.

Default: If `backgroundDisabledImage` is undefined, and the normal background image `backgroundImage` is set, the normal image is used when this view is disabled.

  • 0.9
Titanium.UI.Tab
: String
Sets the color of the tab when it is focused. ...

Sets the color of the tab when it is focused.

On the Android platform, this sets the color of the active tab.

For information about color values, see the "Colors" section of Titanium.UI.

Default: Same as the normal background color of this view.

  • 3.0.0

Overrides: Titanium.UI.View.backgroundFocusedColor

Focused background image for the view, specified as a local file path or URL. ...

Focused background image for the view, specified as a local file path or URL.

For normal views, the focused background is only used if focusable is true.

Default: If `backgroundFocusedImage` is undefined, and the normal background image `backgroundImage` is set, the normal image is used when this view is focused.

  • 0.9
Background image for the view, specified as a local file path or URL. ...

Background image for the view, specified as a local file path or URL.

Default: Default behavior when `backgroundImage` is unspecified depends on the type of view and the platform. For generic views, no image is used. For most controls (buttons, text fields, and so on), platform-specific default images are used.

Selected background color of the view, as a color name or hex triplet. ...

Selected background color of the view, as a color name or hex triplet.

For information about color values, see the "Colors" section of Titanium.UI.

focusable must be true for normal views.

Default: Background color of this view.

  • 0.9
Selected background image url for the view, specified as a local file path or URL. ...

Selected background image url for the view, specified as a local file path or URL.

For normal views, the selected background is only used if focusable is true.

Default: If `backgroundSelectedImage` is undefined, and the normal background image `backgroundImage` is set, the normal image is used when this view is selected.

  • 0.9
Titanium.UI.Tab
: String
Badge value for this tab. ...

Badge value for this tab. null indicates no badge.

  • 0.8
  • 0.8
Titanium.UI.Tab
: String
If this item displays a badge, this color will be used for the badge's background. ...

If this item displays a badge, this color will be used for the badge's background. If set to null, the default background color will be used instead.

Requires: iOS 10.0 and later

For information about color values, see the "Colors" section of Titanium.UI.

  • 6.1.0
  • 6.1.0
Indicates if the proxy will bubble an event to its parent. ...

Indicates if the proxy will bubble an event to its parent.

Some proxies (most commonly views) have a relationship to other proxies, often established by the add() method. For example, for a button added to a window, a click event on the button would bubble up to the window. Other common parents are table sections to their rows, table views to their sections, and scrollable views to their views. Set this property to false to disable the bubbling to the proxy's parent.

Default: true

  • 3.0.0
  • 3.0.0
  • 3.0.0
View's clipping behavior. ...

View's clipping behavior.

Setting this to Titanium.UI.iOS.CLIP_MODE_ENABLED enforces all child views to be clipped to this views bounds. Setting this to Titanium.UI.iOS.CLIP_MODE_DISABLED allows child views to be drawn outside the bounds of this view. When set to Titanium.UI.iOS.CLIP_MODE_DEFAULT or when this property is not set, clipping behavior is inferred. See section on iOS Clipping Behavior in Titanium.UI.View.

Default: Undefined. Behaves as if set to Titanium.UI.iOS.CLIP_MODE_DEFAULT.

  • 3.3.0
  • 3.3.0
Base elevation of the view relative to its parent in pixels. ...

Base elevation of the view relative to its parent in pixels.

Requires: Android 5 and later

The elevation of a view determines the appearance of its shadow. Higher elevations produce larger and softer shadows.

Note: The elevation property only works on Titanium.UI.View objects. Many Android components have a default elevation that cannot be modified. For more information, see Google design guidelines: Elevation and shadows.

  • 5.0.0
Sets the behavior when hiding an object to release or keep the free space ...

Sets the behavior when hiding an object to release or keep the free space

If setting hiddenBehavior to Titanium.UI.HIDDEN_BEHAVIOR_GONE it will automatically release the space the view occupied. For example: in a vertical layout the views below the object will move up when you hide an object with hiddenBehavior:Titanium.UI.HIDDEN_BEHAVIOR_GONE.

This API can be assigned the following constants:

Default: Titanium.UI.HIDDEN_BEHAVIOR_INVISIBLE

  • 6.1.0
Titanium.UI.Tab
icon : String

Icon URL for this tab.

Icon URL for this tab.

iOS Tab Icons

On iOS, tab icons are usually white with a transparent background. The system uses a transparent tint color to indicate whether the tab is active or inactive. In the inactive state, the tint color is based on the tab bar's color tabsBackgroundColor, which defaults to black. In the active state, the tint color is usually blue. Prior to Titanium 3.1, there was no way to override the default active icon tint.

Titanium 3.1 introduced some new ways to customize tab icons, which are supported in iOS 5.0 and above:

Titanium.UI.Tab
: TabIconInsets
The icon inset or outset for each edge. ...

The icon inset or outset for each edge.

Use this property for example to center an icon without providing a title. To do that, set the insets to {top:6} and/or {left:6}. The right and bottom are calculated internally to prevent the icon from mutating.

Default: All insets are zero.

  • 5.2.0
  • 5.2.0
Titanium.UI.Tab
: Boolean
Defines if the icon property of the tab must be used as a mask. ...

Defines if the icon property of the tab must be used as a mask. This property is applicable on iOS 7 and greater.

Requires: iOS 7.0 and later

When this property is true, the color data of the image specified as the icon is ignored and the image is used as an alpha mask. When this is false, the color data of the image is preserved.

Default: true

  • 3.1.3
  • 3.1.3

The Window or TabGroup whose Activity lifecycle should be triggered on the proxy.

The Window or TabGroup whose Activity lifecycle should be triggered on the proxy.

If this property is set to a Window or TabGroup, then the corresponding Activity lifecycle event callbacks will also be called on the proxy. Proxies that require the activity lifecycle will need this property set to the appropriate containing Window or TabGroup.

  • 3.6.0
When on, animate call overrides current animation if applicable. ...

When on, animate call overrides current animation if applicable.

If this property is set to false, the animate call is ignored if the view is currently being animated.

Default: undefined but behaves as false

  • 3.3.0
The preview context used in the 3D-Touch feature "Peek and Pop". ...

The preview context used in the 3D-Touch feature "Peek and Pop".

Requires: iOS 9.0 and later

Preview context to present the "Peek and Pop" of a view. Use an configured instance of Titanium.UI.iOS.PreviewContext here.

Note: This property can only be used on devices running iOS9 or later and supporting 3D-Touch. It is ignored on older devices and can manually be checked using Titanium.UI.iOS.forceTouchSupported.

  • 5.1.0
Background color of the wrapper view when this view is used as either Titanium.UI.ListView.pullView or Titanium.UI.Ta...

Background color of the wrapper view when this view is used as either Titanium.UI.ListView.pullView or Titanium.UI.TableView.headerPullView.

Default: Undefined. Results in a light grey background color on the wrapper view.

  • 3.3.0
  • 3.3.0

Clockwise 2D rotation of the view in degrees.

Clockwise 2D rotation of the view in degrees.

Translation values are applied to the static post layout value.

  • 5.4.0

Clockwise rotation of the view in degrees (x-axis).

Clockwise rotation of the view in degrees (x-axis).

Translation values are applied to the static post layout value.

  • 5.4.0

Clockwise rotation of the view in degrees (y-axis).

Clockwise rotation of the view in degrees (y-axis).

Translation values are applied to the static post layout value.

  • 5.4.0

Scaling of the view in x-axis in pixels.

Scaling of the view in x-axis in pixels.

Translation values are applied to the static post layout value.

  • 5.4.0

Scaling of the view in y-axis in pixels.

Scaling of the view in y-axis in pixels.

Translation values are applied to the static post layout value.

  • 5.4.0
The view's tintColor. ...

The view's tintColor. This property is applicable on iOS 7 and greater.

Requires: iOS 7.0 and later

This property is a direct correspondant of the tintColor property of UIView on iOS. If no value is specified, the tintColor of the View is inherited from its superview.

Default:

  • 3.1.3
  • 3.1.3
Titanium.UI.Tab
title : String

Title for this tab.

Title for this tab.

Titanium.UI.Tab
: String
Defines the color of the title of tab when it's inactive. ...

Defines the color of the title of tab when it's inactive.

Requires: iOS 5.0 and later

The color of the title of the tab when it's inactive. If not defined, it will use the default tint color.

  • 4.1.0
  • 4.1.0
Titanium.UI.Tab
: String
Key identifying a string from the locale file to use for the tab title. ...

Key identifying a string from the locale file to use for the tab title. Only one of title or titleid should be specified.

Determines whether view should receive touch events. ...

Determines whether view should receive touch events.

If false, will forward the events to peers.

Default: true

A material design visual construct that provides an instantaneous visual confirmation of touch point. ...

A material design visual construct that provides an instantaneous visual confirmation of touch point.

Requires: Android 5.0 and later

This is an opt-in feature available from Android Lollipop. Touch feedback is applied only if the backgroundColor is a solid color.

Default: false

  • 6.1.0
Optional touch feedback ripple color. ...

Optional touch feedback ripple color. This has no effect unless touchFeedback is true.

Requires: Android 5.0 and later

Default: Theme provided color.

  • 6.1.0
A name to identify this view in activity transition. ...

A name to identify this view in activity transition.

Requires: Android 5 and later

Name should be unique in the View hierarchy.

  • 5.0.2

Horizontal location of the view relative to its left position in pixels.

Horizontal location of the view relative to its left position in pixels.

Translation values are applied to the static post layout value.

  • 5.0.0

Vertical location of the view relative to its top position in pixels.

Vertical location of the view relative to its top position in pixels.

Translation values are applied to the static post layout value.

  • 5.0.0
Depth of the view relative to its elevation in pixels. ...

Depth of the view relative to its elevation in pixels.

Requires: Android 5 and later

Translation values are applied to the static post layout value.

  • 5.0.0
Determines the color of the shadow. ...

Determines the color of the shadow.

Default: Undefined. Behaves as if transparent.

  • 3.3.0
  • 3.3.0
Determines the offset for the shadow of the view. ...

Determines the offset for the shadow of the view.

Default: Undefined. Behaves as if set to (0,-3)

  • 3.3.0
  • 3.3.0
Determines the blur radius used to create the shadow. ...

Determines the blur radius used to create the shadow.

Default: Undefined. Behaves as if set to 3.

  • 3.3.0
  • 3.3.0
Titanium.UI.Tab
: Titanium.UI.WindowCreation-Only
Root-level tab window. ...

Root-level tab window. All tabs must have at least one root-level tab window.

Defined By

Methods

Adds the specified callback as an event listener for the named event. ...

Adds the specified callback as an event listener for the named event.

Parameters

  • name : String

    Name of the event.

  • callback : Callback<Object>

    Callback function to invoke when the event is fired.

Returns

  • void
Applies the properties to the proxy. ...

Applies the properties to the proxy.

Properties are supplied as a dictionary. Each key-value pair in the object is applied to the proxy such that myproxy[key] = value.

  • 3.0.0
  • 3.0.0
  • 3.0.0

Parameters

  • props : Dictionary

    A dictionary of properties to apply.

Returns

  • void
Titanium.UI.Tab
( window, [options] )
Closes the top-level window for this tab. ...

Closes the top-level window for this tab.

On iOS, this method should be used when closing a window opened from a tab, to correctly maintain the iOS tab group's navigation state. Note that the window to be closed must be passed in as a parameter:

myTab.close(tabWin);

On Android, this method does not take a window parameter.

myTab.close();

On Android, if a window has been opened in front of the tab using Tab.open, a subsequent call to Tab.close is equivalent to calling close on that window. No window stack is maintained, so only the most-recently opened window on a given tab can be closed in this way.

All platforms accept an optional options parameter. The only supported property for this dictionary is the animated flag, which specifies whether the window close should be animated. animated is true by default.

Parameters

  • window : Titanium.UI.Window

    Window to close. This parameter must be omitted on Android.

  • options : Object (optional)

    Dictionary of display and animation settings to use when closing the window. Identical to the options parameter to Window.close. iOS only supports the animated parameter.

Returns

  • void
( point, destinationView ) : Point
Translates a point from this view's coordinate system to another view's coordinate system. ...

Translates a point from this view's coordinate system to another view's coordinate system.

Returns null if either view is not in the view hierarchy.

Keep in mind that views may be removed from the view hierarchy if their window is blurred or if the view is offscreen (such as in some situations with Titanium.UI.ScrollableView).

If this view is a Titanium.UI.ScrollView, the view's x and y offsets are subtracted from the return value.

  • 1.8
  • 1.8
  • 1.8

Parameters

  • point : Point

    A point in this view's coordinate system.

    If this argument is missing an x or y property, or the properties can not be converted into numbers, an exception will be raised.

  • destinationView : Titanium.UI.View

    View that specifies the destination coordinate system to convert to. If this argument is not a view, an exception will be raised.

Returns

Finishes a batch update of the View's layout properties and schedules a layout pass of the view tree. ...

Finishes a batch update of the View's layout properties and schedules a layout pass of the view tree.

deprecated since 3.0.0

Use the <Titanium.Proxy.applyProperties> method to batch-update layout properties.

Since the layout pass scheduled is asynchronous, the rect and size values may not be available immediately after finishLayout is called.

To be notified when the layout pass completes, add a listener for the postlayout event.

  • 2.0.0
  • 2.0.0
  • 2.0.0

Returns

  • void
Fires a synthesized event to any registered listeners. ...

Fires a synthesized event to any registered listeners.

Parameters

  • name : String

    Name of the event.

  • event : Dictionary

    A dictionary of keys and values to add to the Titanium.Event object sent to the listeners.

Returns

  • void
Titanium.UI.Tab
( ) : Boolean
Gets the value of the active property. ...

Gets the value of the active property.

  • 0.8
  • 0.8

Returns

  • Boolean
Titanium.UI.Tab
( ) : String
Gets the value of the activeIcon property. ...

Gets the value of the activeIcon property.

  • 3.1.0
  • 3.1.0

Returns

  • String
Titanium.UI.Tab
( ) : Boolean
Gets the value of the activeIconIsMask property. ...

Gets the value of the activeIconIsMask property.

  • 3.1.3
  • 3.1.3

Returns

  • Boolean
Titanium.UI.Tab
( ) : String
Gets the value of the activeTitleColor property. ...

Gets the value of the activeTitleColor property.

  • 4.1.0
  • 4.1.0

Returns

  • String
Gets the value of the apiName property. ...

Gets the value of the apiName property.

  • 3.2.0
  • 3.2.0
  • 3.2.0

Returns

  • String
Titanium.UI.Tab
( ) : String
Gets the value of the backgroundColor property. ...

Gets the value of the backgroundColor property.

  • 3.0.0

Returns

  • String

Overrides: Titanium.UI.View.getBackgroundColor

Gets the value of the backgroundDisabledColor property. ...

Gets the value of the backgroundDisabledColor property.

  • 0.9

Returns

  • String
Gets the value of the backgroundDisabledImage property. ...

Gets the value of the backgroundDisabledImage property.

  • 0.9

Returns

  • String
Titanium.UI.Tab
( ) : String
Gets the value of the backgroundFocusedColor property. ...

Gets the value of the backgroundFocusedColor property.

  • 3.0.0

Returns

  • String

Overrides: Titanium.UI.View.getBackgroundFocusedColor

Gets the value of the backgroundFocusedImage property. ...

Gets the value of the backgroundFocusedImage property.

  • 0.9

Returns

  • String
Gets the value of the backgroundImage property. ...

Gets the value of the backgroundImage property.

Returns

  • String
Gets the value of the backgroundSelectedColor property. ...

Gets the value of the backgroundSelectedColor property.

  • 0.9

Returns

  • String
Gets the value of the backgroundSelectedImage property. ...

Gets the value of the backgroundSelectedImage property.

  • 0.9

Returns

  • String
Titanium.UI.Tab
( ) : String
Gets the value of the badge property. ...

Gets the value of the badge property.

  • 0.8
  • 0.8

Returns

  • String
Titanium.UI.Tab
( ) : String
Gets the value of the badgeColor property. ...

Gets the value of the badgeColor property.

  • 6.1.0
  • 6.1.0

Returns

  • String
Gets the value of the bubbleParent property. ...

Gets the value of the bubbleParent property.

  • 3.0.0
  • 3.0.0
  • 3.0.0

Returns

  • Boolean
Gets the value of the clipMode property. ...

Gets the value of the clipMode property.

  • 3.3.0
  • 3.3.0

Returns

  • Number
Gets the value of the elevation property. ...

Gets the value of the elevation property.

  • 5.0.0

Returns

  • Number
Gets the value of the hiddenBehavior property. ...

Gets the value of the hiddenBehavior property.

  • 6.1.0

Returns

  • Number
Titanium.UI.Tab
( ) : String
Gets the value of the icon property. ...

Gets the value of the icon property.

Returns

  • String
Titanium.UI.Tab
( ) : TabIconInsets
Gets the value of the iconInsets property. ...

Gets the value of the iconInsets property.

  • 5.2.0
  • 5.2.0

Returns

Titanium.UI.Tab
( ) : Boolean
Gets the value of the iconIsMask property. ...

Gets the value of the iconIsMask property.

  • 3.1.3
  • 3.1.3

Returns

  • Boolean
Gets the value of the lifecycleContainer property. ...

Gets the value of the lifecycleContainer property.

  • 3.6.0

Returns

Gets the value of the overrideCurrentAnimation property. ...

Gets the value of the overrideCurrentAnimation property.

  • 3.3.0

Returns

  • Boolean
Gets the value of the previewContext property. ...

Gets the value of the previewContext property.

  • 5.1.0

Returns

Gets the value of the pullBackgroundColor property. ...

Gets the value of the pullBackgroundColor property.

  • 3.3.0
  • 3.3.0

Returns

  • String
Gets the value of the rotation property. ...

Gets the value of the rotation property.

  • 5.4.0

Returns

  • Number
Gets the value of the rotationX property. ...

Gets the value of the rotationX property.

  • 5.4.0

Returns

  • Number
Gets the value of the rotationY property. ...

Gets the value of the rotationY property.

  • 5.4.0

Returns

  • Number
Gets the value of the scaleX property. ...

Gets the value of the scaleX property.

  • 5.4.0

Returns

  • Number
Gets the value of the scaleY property. ...

Gets the value of the scaleY property.

  • 5.4.0

Returns

  • Number
Gets the value of the tintColor property. ...

Gets the value of the tintColor property.

  • 3.1.3
  • 3.1.3

Returns

  • String
Titanium.UI.Tab
( ) : String
Gets the value of the title property. ...

Gets the value of the title property.

Returns

  • String
Titanium.UI.Tab
( ) : String
Gets the value of the titleColor property. ...

Gets the value of the titleColor property.

  • 4.1.0
  • 4.1.0

Returns

  • String
Titanium.UI.Tab
( ) : String
Gets the value of the titleid property. ...

Gets the value of the titleid property.

Returns

  • String
Gets the value of the touchEnabled property. ...

Gets the value of the touchEnabled property.

Returns

  • Boolean
Gets the value of the touchFeedback property. ...

Gets the value of the touchFeedback property.

  • 6.1.0

Returns

  • Boolean
Gets the value of the touchFeedbackColor property. ...

Gets the value of the touchFeedbackColor property.

  • 6.1.0

Returns

  • String
Gets the value of the transitionName property. ...

Gets the value of the transitionName property.

  • 5.0.2

Returns

  • String
Gets the value of the translationX property. ...

Gets the value of the translationX property.

  • 5.0.0

Returns

  • Number
Gets the value of the translationY property. ...

Gets the value of the translationY property.

  • 5.0.0

Returns

  • Number
Gets the value of the translationZ property. ...

Gets the value of the translationZ property.

  • 5.0.0

Returns

  • Number
Returns the matching view of a given view ID. ...

Returns the matching view of a given view ID.

  • 6.1.0
  • 6.1.0
  • 6.1.0

Parameters

  • id : String

    The ID of the view that should be returned. Use the id property in your views to enable it for indexing in this method.

Returns

Gets the value of the viewShadowColor property. ...

Gets the value of the viewShadowColor property.

  • 3.3.0
  • 3.3.0

Returns

  • String
Gets the value of the viewShadowOffset property. ...

Gets the value of the viewShadowOffset property.

  • 3.3.0
  • 3.3.0

Returns

Gets the value of the viewShadowRadius property. ...

Gets the value of the viewShadowRadius property.

  • 3.3.0
  • 3.3.0

Returns

  • Number
Titanium.UI.Tab
( ) : Titanium.UI.Window
Gets the value of the window property. ...

Gets the value of the window property.

Returns

Inserts a view at the specified position in the children array. ...

Inserts a view at the specified position in the children array.

Useful if the layout property is set to horizontal or vertical.

  • 3.3.0
  • 3.3.0
  • 3.3.0

Parameters

  • params : Dictionary

    Pass an object with the following key-value pairs:

    • view (Titanium.UI.View): View to insert
    • position (Number): Position in the children array to insert the view. If omitted, inserts the view to the end of the array.

Returns

  • void
Titanium.UI.Tab
( window, options )
Opens a new window. ...

Opens a new window.

On iOS, the new window is opened as the top window in the tab's window stack. On Android, the new window is opened as a new, heavyweight window, obscuring the tab group.

Parameters

  • window : Titanium.UI.Window

    Window to open.

  • options : Object

    Dictionary of display and animation settings to use when opening the window. Identical to the options parameter to Window.open. iOS only supports the animated parameter.

Returns

  • void
Titanium.UI.Tab
( options )
Closes all windows that are currently opened inside the tab. ...

Closes all windows that are currently opened inside the tab.

Note that only the close event of the most recently opened window is fired.

  • 6.2.0
  • 6.2.0
  • 6.2.0

Parameters

  • options : Dictionary

    Options supporting a single animated boolean property to determine whether the windows will be animated while being closed (default: false).

Returns

  • void
Removes the specified callback as an event listener for the named event. ...

Removes the specified callback as an event listener for the named event.

Multiple listeners can be registered for the same event, so the callback parameter is used to determine which listener to remove.

When adding a listener, you must save a reference to the callback function in order to remove the listener later:

var listener = function() { Ti.API.info("Event listener called."); }
window.addEventListener('click', listener);

To remove the listener, pass in a reference to the callback function:

window.removeEventListener('click', listener);

Parameters

  • name : String

    Name of the event.

  • callback : Callback<Object>

    Callback function to remove. Must be the same function passed to addEventListener.

Returns

  • void
Replaces a view at the specified position in the children array. ...

Replaces a view at the specified position in the children array.

Useful if the layout property is set to horizontal or vertical.

  • 3.3.0
  • 3.3.0
  • 3.3.0

Parameters

  • params : Dictionary

    Pass an object with the following key-value pairs:

    • view (Titanium.UI.View): View to insert
    • position (Number): Position in the children array of the view elment to replace.

Returns

  • void
Titanium.UI.Tab
( active )
Sets the value of the active property. ...

Sets the value of the active property.

  • 0.8
  • 0.8

Parameters

  • active : Boolean

    New value for the property.

Returns

  • void
Titanium.UI.Tab
( activeIcon )
Sets the value of the activeIcon property. ...

Sets the value of the activeIcon property.

  • 3.1.0
  • 3.1.0

Parameters

  • activeIcon : String

    New value for the property.

Returns

  • void
Titanium.UI.Tab
( activeIconIsMask )
Sets the value of the activeIconIsMask property. ...

Sets the value of the activeIconIsMask property.

  • 3.1.3
  • 3.1.3

Parameters

  • activeIconIsMask : Boolean

    New value for the property.

Returns

  • void
Titanium.UI.Tab
( activeTitleColor )
Sets the value of the activeTitleColor property. ...

Sets the value of the activeTitleColor property.

  • 4.1.0
  • 4.1.0

Parameters

  • activeTitleColor : String

    New value for the property.

Returns

  • void
Titanium.UI.Tab
( backgroundColor )
Sets the value of the backgroundColor property. ...

Sets the value of the backgroundColor property.

  • 3.0.0

Parameters

  • backgroundColor : String

    New value for the property.

Returns

  • void

Overrides: Titanium.UI.View.setBackgroundColor

Sets the value of the backgroundDisabledColor property. ...

Sets the value of the backgroundDisabledColor property.

  • 0.9

Parameters

  • backgroundDisabledColor : String

    New value for the property.

Returns

  • void
Sets the value of the backgroundDisabledImage property. ...

Sets the value of the backgroundDisabledImage property.

  • 0.9

Parameters

  • backgroundDisabledImage : String

    New value for the property.

Returns

  • void
Titanium.UI.Tab
( backgroundFocusedColor )
Sets the value of the backgroundFocusedColor property. ...

Sets the value of the backgroundFocusedColor property.

  • 3.0.0

Parameters

  • backgroundFocusedColor : String

    New value for the property.

Returns

  • void

Overrides: Titanium.UI.View.setBackgroundFocusedColor

Sets the value of the backgroundFocusedImage property. ...

Sets the value of the backgroundFocusedImage property.

  • 0.9

Parameters

  • backgroundFocusedImage : String

    New value for the property.

Returns

  • void
Sets the value of the backgroundImage property. ...

Sets the value of the backgroundImage property.

Parameters

  • backgroundImage : String

    New value for the property.

Returns

  • void
Sets the value of the backgroundSelectedColor property. ...

Sets the value of the backgroundSelectedColor property.

  • 0.9

Parameters

  • backgroundSelectedColor : String

    New value for the property.

Returns

  • void
Sets the value of the backgroundSelectedImage property. ...

Sets the value of the backgroundSelectedImage property.

  • 0.9

Parameters

  • backgroundSelectedImage : String

    New value for the property.

Returns

  • void
Titanium.UI.Tab
( badge )
Sets the value of the badge property. ...

Sets the value of the badge property.

  • 0.8
  • 0.8

Parameters

  • badge : String

    New value for the property.

Returns

  • void
Titanium.UI.Tab
( badgeColor )
Sets the value of the badgeColor property. ...

Sets the value of the badgeColor property.

  • 6.1.0
  • 6.1.0

Parameters

  • badgeColor : String

    New value for the property.

Returns

  • void
Sets the value of the bubbleParent property. ...

Sets the value of the bubbleParent property.

  • 3.0.0
  • 3.0.0
  • 3.0.0

Parameters

  • bubbleParent : Boolean

    New value for the property.

Returns

  • void
Sets the value of the clipMode property. ...

Sets the value of the clipMode property.

  • 3.3.0
  • 3.3.0

Parameters

  • clipMode : Number

    New value for the property.

Returns

  • void
Sets the value of the elevation property. ...

Sets the value of the elevation property.

  • 5.0.0

Parameters

  • elevation : Number

    New value for the property.

Returns

  • void
Sets the value of the hiddenBehavior property. ...

Sets the value of the hiddenBehavior property.

  • 6.1.0

Parameters

  • hiddenBehavior : Number

    New value for the property.

Returns

  • void
Titanium.UI.Tab
( icon )
Sets the value of the icon property. ...

Sets the value of the icon property.

Parameters

  • icon : String

    New value for the property.

Returns

  • void
Titanium.UI.Tab
( iconInsets )
Sets the value of the iconInsets property. ...

Sets the value of the iconInsets property.

  • 5.2.0
  • 5.2.0

Parameters

Returns

  • void
Titanium.UI.Tab
( iconIsMask )
Sets the value of the iconIsMask property. ...

Sets the value of the iconIsMask property.

  • 3.1.3
  • 3.1.3

Parameters

  • iconIsMask : Boolean

    New value for the property.

Returns

  • void
Sets the value of the lifecycleContainer property. ...

Sets the value of the lifecycleContainer property.

  • 3.6.0

Parameters

Returns

  • void
Sets the value of the overrideCurrentAnimation property. ...

Sets the value of the overrideCurrentAnimation property.

  • 3.3.0

Parameters

  • overrideCurrentAnimation : Boolean

    New value for the property.

Returns

  • void
Sets the value of the previewContext property. ...

Sets the value of the previewContext property.

  • 5.1.0

Parameters

Returns

  • void
Sets the value of the pullBackgroundColor property. ...

Sets the value of the pullBackgroundColor property.

  • 3.3.0
  • 3.3.0

Parameters

  • pullBackgroundColor : String

    New value for the property.

Returns

  • void
Sets the value of the rotation property. ...

Sets the value of the rotation property.

  • 5.4.0

Parameters

  • rotation : Number

    New value for the property.

Returns

  • void
Sets the value of the rotationX property. ...

Sets the value of the rotationX property.

  • 5.4.0

Parameters

  • rotationX : Number

    New value for the property.

Returns

  • void
Sets the value of the rotationY property. ...

Sets the value of the rotationY property.

  • 5.4.0

Parameters

  • rotationY : Number

    New value for the property.

Returns

  • void
Sets the value of the scaleX property. ...

Sets the value of the scaleX property.

  • 5.4.0

Parameters

  • scaleX : Number

    New value for the property.

Returns

  • void
Sets the value of the scaleY property. ...

Sets the value of the scaleY property.

  • 5.4.0

Parameters

  • scaleY : Number

    New value for the property.

Returns

  • void
Sets the value of the tintColor property. ...

Sets the value of the tintColor property.

  • 3.1.3
  • 3.1.3

Parameters

  • tintColor : String

    New value for the property.

Returns

  • void
Titanium.UI.Tab
( title )
Sets the value of the title property. ...

Sets the value of the title property.

Parameters

  • title : String

    New value for the property.

Returns

  • void
Titanium.UI.Tab
( titleColor )
Sets the value of the titleColor property. ...

Sets the value of the titleColor property.

  • 4.1.0
  • 4.1.0

Parameters

  • titleColor : String

    New value for the property.

Returns

  • void
Titanium.UI.Tab
( titleid )
Sets the value of the titleid property. ...

Sets the value of the titleid property.

Parameters

  • titleid : String

    New value for the property.

Returns

  • void
Sets the value of the touchEnabled property. ...

Sets the value of the touchEnabled property.

Parameters

  • touchEnabled : Boolean

    New value for the property.

Returns

  • void
Sets the value of the touchFeedback property. ...

Sets the value of the touchFeedback property.

  • 6.1.0

Parameters

  • touchFeedback : Boolean

    New value for the property.

Returns

  • void
Sets the value of the touchFeedbackColor property. ...

Sets the value of the touchFeedbackColor property.

  • 6.1.0

Parameters

  • touchFeedbackColor : String

    New value for the property.

Returns

  • void
Sets the value of the transitionName property. ...

Sets the value of the transitionName property.

  • 5.0.2

Parameters

  • transitionName : String

    New value for the property.

Returns

  • void
Sets the value of the translationX property. ...

Sets the value of the translationX property.

  • 5.0.0

Parameters

  • translationX : Number

    New value for the property.

Returns

  • void
Sets the value of the translationY property. ...

Sets the value of the translationY property.

  • 5.0.0

Parameters

  • translationY : Number

    New value for the property.

Returns

  • void
Sets the value of the translationZ property. ...

Sets the value of the translationZ property.

  • 5.0.0

Parameters

  • translationZ : Number

    New value for the property.

Returns

  • void
Sets the value of the viewShadowColor property. ...

Sets the value of the viewShadowColor property.

  • 3.3.0
  • 3.3.0

Parameters

  • viewShadowColor : String

    New value for the property.

Returns

  • void
Sets the value of the viewShadowOffset property. ...

Sets the value of the viewShadowOffset property.

  • 3.3.0
  • 3.3.0

Parameters

  • viewShadowOffset : Point

    New value for the property.

Returns

  • void
Sets the value of the viewShadowRadius property. ...

Sets the value of the viewShadowRadius property.

  • 3.3.0
  • 3.3.0

Parameters

  • viewShadowRadius : Number

    New value for the property.

Returns

  • void
Titanium.UI.Tab
( window )
Sets the root window that appears in the tab. ...

Sets the root window that appears in the tab.

You can only use this method to set the tab's root window before the TabGroup containing this tab is openened, that is, once the TabGroup is displayed, you cannot change the root window that appears in the tab.

Parameters

Returns

  • void
Starts a batch update of this view's layout properties. ...

Starts a batch update of this view's layout properties.

deprecated since 3.0.0

Use the <Titanium.Proxy.applyProperties> method to batch-update layout properties.

To prevent a layout pass each time a property is modified, call startLayout before changing any properties that may change this view's layout. This initiates a batch update mode where layout changes are deferred.

Call finishLayout to end batch update mode and trigger a layout pass. For example:

view.startLayout();
view.top = 50;
view.left = 50;
view.finishLayout();

Note that any property changes made during the batch update may be deferred until finishLayout is called. This may vary somewhat by platform. For example, changing the text of a label may trigger a layout pass. In iOS, updating the label text is deferred.

See also: updateLayout, finishLayout, postlayout event.

  • 2.0.0
  • 2.0.0
  • 2.0.0

Returns

  • void
( [callback], [honorScaleFactor] ) : Titanium.Blob
Returns an image of the rendered view, as a Blob. ...

Returns an image of the rendered view, as a Blob.

The honorScaleFactor method is only supported on iOS.

Parameters

  • callback : Callback<Titanium.Blob> (optional)

    Function to be invoked upon completion. If non-null, this method will be performed asynchronously. If null, it will be performed immediately.

  • honorScaleFactor : Boolean (optional)

    Determines whether the image is scaled based on scale factor of main screen. (iOS only)

    When set to true, image is scale factor is honored. When set to false, the image in the blob has the same dimensions for retina and non-retina devices.

Returns

( params )deprecated
Performs a batch update of all supplied layout properties and schedules a layout pass after they have been updated. ...

Performs a batch update of all supplied layout properties and schedules a layout pass after they have been updated.

deprecated since 3.0.0

Use the <Titanium.Proxy.applyProperties> method to batch-update layout properties.

This is another way to perform a batch update. The updateLayout method is called with a dictionary of layout properties to perform the batch update. For example:

view.updateLayout({top:50, left:50});

This is equivalent to the following:

view.startLayout();
view.top = 50;
view.left = 50;
view.finishLayout();

See also: startLayout, finishLayout, postlayout event.

  • 2.0.0
  • 2.0.0
  • 2.0.0

Parameters

  • params : Dictionary

    Layout properties to be updated.

Returns

  • void
Defined By

Events

Titanium.UI.Tab
deprecated
Fired when the tab loses focus. ...

Fired when the tab loses focus.

deprecated since 5.2.0

Use <Titanium.UI.Tab.unselected> instead.

Properties

  • index : Number

    Index of the current active tab.

  • previousIndex : Number

    Index of the previous active tab.

  • tab : Titanium.UI.Tab

    Current active tab object.

  • previousTab : Titanium.UI.Tab

    Previous active tab object.

  • source : Object

    Source object that fired the event.

    •  
    •  
    •  
  • type : String

    Name of the event fired.

    •  
    •  
    •  
  • bubbles : Boolean

    True if the event will try to bubble up if possible.

    •  
    •  
    •  
  • cancelBubble : Boolean

    Set to true to stop the event from bubbling.

    •  
    •  
    •  
Titanium.UI.Tab
Fired when this tab is clicked in the tab group. ...

Fired when this tab is clicked in the tab group.

There is a subtle difference between singletap and click events.

A singletap event is generated when the user taps the screen briefly without moving their finger. This gesture will also generate a click event.

However, a click event can also be generated when the user touches, moves their finger, and then removes it from the screen.

On Android, a click event can also be generated by a trackball click.

  • 0.9
  • 0.9
  • 0.9

Properties

  • x : Number

    X coordinate of the event from the source view's coordinate system.

  • y : Number

    Y coordinate of the event from the source view's coordinate system.

  • source : Object

    Source object that fired the event.

    •  
    •  
    •  
  • type : String

    Name of the event fired.

    •  
    •  
    •  
  • bubbles : Boolean

    True if the event will try to bubble up if possible.

    •  
    •  
    •  
  • cancelBubble : Boolean

    Set to true to stop the event from bubbling.

    •  
    •  
    •  

Overrides: Titanium.UI.View.click

Fired when the device detects a double click against the view. ...

Fired when the device detects a double click against the view.

Properties

  • x : Number

    X coordinate of the event from the source view's coordinate system.

  • y : Number

    Y coordinate of the event from the source view's coordinate system.

  • source : Object

    Source object that fired the event.

    •  
    •  
    •  
  • type : String

    Name of the event fired.

    •  
    •  
    •  
  • bubbles : Boolean

    True if the event will try to bubble up if possible.

    •  
    •  
    •  
  • cancelBubble : Boolean

    Set to true to stop the event from bubbling.

    •  
    •  
    •  
Fired when the device detects a double tap against the view. ...

Fired when the device detects a double tap against the view.

Properties

  • x : Number

    X coordinate of the event from the source view's coordinate system.

  • y : Number

    Y coordinate of the event from the source view's coordinate system.

  • source : Object

    Source object that fired the event.

    •  
    •  
    •  
  • type : String

    Name of the event fired.

    •  
    •  
    •  
  • bubbles : Boolean

    True if the event will try to bubble up if possible.

    •  
    •  
    •  
  • cancelBubble : Boolean

    Set to true to stop the event from bubbling.

    •  
    •  
    •  
Titanium.UI.Tab
deprecated
Fired when the tab gains focus. ...

Fired when the tab gains focus.

deprecated since 5.2.0

Use <Titanium.UI.Tab.selected> instead.

This event only fires when using the trackball to navigate.

  • 0.9
  • 0.8
  • 0.8

Properties

  • index : Number

    Index of the current active tab.

  • previousIndex : Number

    Index of the previous active tab.

  • tab : Titanium.UI.Tab

    Current active tab object.

  • previousTab : Titanium.UI.Tab

    Previous active tab object.

  • source : Object

    Source object that fired the event.

    •  
    •  
    •  
  • type : String

    Name of the event fired.

    •  
    •  
    •  
  • bubbles : Boolean

    True if the event will try to bubble up if possible.

    •  
    •  
    •  
  • cancelBubble : Boolean

    Set to true to stop the event from bubbling.

    •  
    •  
    •  

Overrides: Titanium.UI.View.focus

Fired when the device detects a long press. ...

Fired when the device detects a long press.

A long press is generated by touching and holding on the touchscreen. Unlike a longclick, it does not respond to the trackball button.

The event occurs before the finger is lifted.

A longpress and a longclick can occur together.

In contrast to a longclick, this event returns the x and y coordinates of the touch.

Properties

  • x : Number

    X coordinate of the event from the source view's coordinate system.

  • y : Number

    Y coordinate of the event from the source view's coordinate system.

  • source : Object

    Source object that fired the event.

    •  
    •  
    •  
  • type : String

    Name of the event fired.

    •  
    •  
    •  
  • bubbles : Boolean

    True if the event will try to bubble up if possible.

    •  
    •  
    •  
  • cancelBubble : Boolean

    Set to true to stop the event from bubbling.

    •  
    •  
    •  
Fired when a layout cycle is finished. ...

Fired when a layout cycle is finished.

This event is fired when the view and its ancestors have been laid out. The rect and size values should be usable when this event is fired.

This event is typically triggered by either changing layout properties or by changing the orientation of the device. Note that changing the layout of child views or ancestors can also trigger a relayout of this view.

Note that altering any properties that affect layout from the postlayout callback may result in an endless loop.

  • 2.0.0
  • 2.0.0
  • 2.0.0

Properties

  • source : Object

    Source object that fired the event.

    •  
    •  
    •  
  • type : String

    Name of the event fired.

    •  
    •  
    •  
  • bubbles : Boolean

    True if the event will try to bubble up if possible.

    •  
    •  
    •  
  • cancelBubble : Boolean

    Set to true to stop the event from bubbling.

    •  
    •  
    •  
Titanium.UI.Tab
Fired when the tab is selected. ...

Fired when the tab is selected.

  • 3.6.0

Properties

  • source : Object

    Source object that fired the event.

    •  
    •  
    •  
  • type : String

    Name of the event fired.

    •  
    •  
    •  
  • bubbles : Boolean

    True if the event will try to bubble up if possible.

    •  
    •  
    •  
  • cancelBubble : Boolean

    Set to true to stop the event from bubbling.

    •  
    •  
    •  
Fired when the device detects a single tap against the view. ...

Fired when the device detects a single tap against the view.

Properties

  • x : Number

    X coordinate of the event from the source view's coordinate system.

  • y : Number

    Y coordinate of the event from the source view's coordinate system.

  • source : Object

    Source object that fired the event.

    •  
    •  
    •  
  • type : String

    Name of the event fired.

    •  
    •  
    •  
  • bubbles : Boolean

    True if the event will try to bubble up if possible.

    •  
    •  
    •  
  • cancelBubble : Boolean

    Set to true to stop the event from bubbling.

    •  
    •  
    •  
Fired when the device detects a swipe gesture against the view. ...

Fired when the device detects a swipe gesture against the view.

Properties

  • direction : String

    Direction of the swipe--either 'left', 'right', 'up', or 'down'.

  • x : Number

    X coordinate of the event's endpoint from the source view's coordinate system.

  • y : Number

    Y coordinate of the event's endpoint from the source view's coordinate system.

  • source : Object

    Source object that fired the event.

    •  
    •  
    •  
  • type : String

    Name of the event fired.

    •  
    •  
    •  
  • bubbles : Boolean

    True if the event will try to bubble up if possible.

    •  
    •  
    •  
  • cancelBubble : Boolean

    Set to true to stop the event from bubbling.

    •  
    •  
    •  
Fired when a touch event is interrupted by the device. ...

Fired when a touch event is interrupted by the device.

A touchcancel can happen in circumstances such as an incoming call to allow the UI to clean up state.

Properties

  • x : Number

    X coordinate of the event from the source view's coordinate system.

  • y : Number

    Y coordinate of the event from the source view's coordinate system.

  • force : Number

    The current force value of the touch event. Note: This property is only available for iOS devices that support 3D-Touch and run 9.0 or later and on some Android devices.

  • size : Number

    The current size of the touch area. Note: This property is only available on some Android devices.

  • maximumPossibleForce : Number

    Maximum possible value of the force property. Note: This property is only available for iOS devices that support 3D-Touch and run 9.0 or later.

  • altitudeAngle : Number

    A value which indicates the stylus angle on the screen. If the stylus is perpendicular to the screen or no stylus is being used, the value will be Pi/2. If the stylus is parallel to the screen, the value will be 0. Note: This property is only available for iOS devices that support 3D-Touch and are 9.1 or later.

  • timestamp : Number

    The time (in seconds) when the touch was used in correlation with the system start up. Note: This property is only available for iOS devices that support 3D-Touch and run 9.0 or later.

  • azimuthUnitVectorInViewX : Number

    The x value of the unit vector that points in the direction of the azimuth of the stylus. Note: This property is only available for iOS devices that support the Apple Pencil and are 9.1 or later.

  • azimuthUnitVectorInViewY : Number

    The y value of the unit vector that points in the direction of the azimuth of the stylus. Note: This property is only available for iOS devices that support the Apple Pencil and are 9.1 or later.

  • source : Object

    Source object that fired the event.

    •  
    •  
    •  
  • type : String

    Name of the event fired.

    •  
    •  
    •  
  • bubbles : Boolean

    True if the event will try to bubble up if possible.

    •  
    •  
    •  
  • cancelBubble : Boolean

    Set to true to stop the event from bubbling.

    •  
    •  
    •  
Fired when a touch event is completed. ...

Fired when a touch event is completed.

On the Android platform, other gesture events, such as longpress or swipe, cancel touch events, so this event may not be triggered after a touchstart event.

Properties

  • x : Number

    X coordinate of the event from the source view's coordinate system.

  • y : Number

    Y coordinate of the event from the source view's coordinate system.

  • force : Number

    The current force value of the touch event. Note: This property is only available for iOS devices that support 3D-Touch and run 9.0 or later and on some Android devices.

  • size : Number

    The current size of the touch area. Note: This property is only available on some Android devices.

  • maximumPossibleForce : Number

    Maximum possible value of the force property. Note: This property is only available for iOS devices that support 3D-Touch and run 9.0 or later.

  • altitudeAngle : Number

    A value which indicates the stylus angle on the screen. If the stylus is perpendicular to the screen or no stylus is being used, the value will be Pi/2. If the stylus is parallel to the screen, the value will be 0. Note: This property is only available for iOS devices that support 3D-Touch and are 9.1 or later.

  • timestamp : Number

    The time (in seconds) when the touch was used in correlation with the system start up. Note: This property is only available for iOS devices that support 3D-Touch and run 9.0 or later.

  • azimuthUnitVectorInViewX : Number

    The x value of the unit vector that points in the direction of the azimuth of the stylus. Note: This property is only available for iOS devices that support the Apple Pencil and are 9.1 or later.

  • azimuthUnitVectorInViewY : Number

    The y value of the unit vector that points in the direction of the azimuth of the stylus. Note: This property is only available for iOS devices that support the Apple Penciland are 9.1 or later.

  • source : Object

    Source object that fired the event.

    •  
    •  
    •  
  • type : String

    Name of the event fired.

    •  
    •  
    •  
  • bubbles : Boolean

    True if the event will try to bubble up if possible.

    •  
    •  
    •  
  • cancelBubble : Boolean

    Set to true to stop the event from bubbling.

    •  
    •  
    •  
Fired as soon as the device detects movement of a touch. ...

Fired as soon as the device detects movement of a touch.

Event coordinates are always relative to the view in which the initial touch occurred

Properties

  • x : Number

    X coordinate of the event from the source view's coordinate system.

  • y : Number

    Y coordinate of the event from the source view's coordinate system.

  • force : Number

    The current force value of the touch event. Note: This property is only available for iOS devices that support 3D-Touch and run 9.0 or later and on some Android devices.

  • size : Number

    The current size of the touch area. Note: This property is only available on some Android devices.

  • maximumPossibleForce : Number

    Maximum possible value of the force property. Note: This property is only available for iOS devices that support 3D-Touch and run 9.0 or later.

  • altitudeAngle : Number

    A value which indicates the stylus angle on the screen. If the stylus is perpendicular to the screen or no stylus is being used, the value will be Pi/2. If the stylus is parallel to the screen, the value will be 0. Note: This property is only available for iOS devices that support 3D-Touch and are 9.1 or later.

  • timestamp : Number

    The time (in seconds) when the touch was used in correlation with the system start up. Note: This property is only available for iOS devices that support 3D-Touch and run 9.0 or later.

  • azimuthUnitVectorInViewX : Number

    The x value of the unit vector that points in the direction of the azimuth of the stylus. Note: This property is only available for iOS devices that support the Apple Pencil and are 9.1 or later.

  • azimuthUnitVectorInViewY : Number

    The y value of the unit vector that points in the direction of the azimuth of the stylus. Note: This property is only available for iOS devices that support the Apple Pencil and are 9.1 or later.

  • source : Object

    Source object that fired the event.

    •  
    •  
    •  
  • type : String

    Name of the event fired.

    •  
    •  
    •  
  • bubbles : Boolean

    True if the event will try to bubble up if possible.

    •  
    •  
    •  
  • cancelBubble : Boolean

    Set to true to stop the event from bubbling.

    •  
    •  
    •  
Fired as soon as the device detects a touch gesture. ...

Fired as soon as the device detects a touch gesture.

Properties

  • x : Number

    X coordinate of the event from the source view's coordinate system.

  • y : Number

    Y coordinate of the event from the source view's coordinate system.

  • force : Number

    The current force value of the touch event. Note: This property is only available for iOS devices that support 3D-Touch and run 9.0 or later and on some Android devices.

  • size : Number

    The current size of the touch area. Note: This property is only available on some Android devices.

  • maximumPossibleForce : Number

    Maximum possible value of the force property. Note: This property is only available for iOS devices that support 3D-Touch and run 9.0 or later.

  • altitudeAngle : Number

    A value which indicates the stylus angle on the screen. If the stylus is perpendicular to the screen or no stylus is being used, the value will be Pi/2. If the stylus is parallel to the screen, the value will be 0. Note: This property is only available for iOS devices that support 3D-Touch and are 9.1 or later.

  • timestamp : Number

    The time (in seconds) when the touch was used in correlation with the system start up. Note: This property is only available for iOS devices that support 3D-Touch and run 9.0 or later.

  • azimuthUnitVectorInViewX : Number

    The x value of the unit vector that points in the direction of the azimuth of the stylus. Note: This property is only available for iOS devices that support the Apple Pencil and are 9.1 or later.

  • azimuthUnitVectorInViewY : Number

    The y value of the unit vector that points in the direction of the azimuth of the stylus. Note: This property is only available for iOS devices that support the Apple Pencil and are 9.1 or later.

  • source : Object

    Source object that fired the event.

    •  
    •  
    •  
  • type : String

    Name of the event fired.

    •  
    •  
    •  
  • bubbles : Boolean

    True if the event will try to bubble up if possible.

    •  
    •  
    •  
  • cancelBubble : Boolean

    Set to true to stop the event from bubbling.

    •  
    •  
    •  
Titanium.UI.Tab
Fired when the tab is unselected. ...

Fired when the tab is unselected.

  • 3.6.0

Properties

  • source : Object

    Source object that fired the event.

    •  
    •  
    •  
  • type : String

    Name of the event fired.

    •  
    •  
    •  
  • bubbles : Boolean

    True if the event will try to bubble up if possible.

    •  
    •  
    •  
  • cancelBubble : Boolean

    Set to true to stop the event from bubbling.

    •  
    •  
    •