@maccesar/titools 2.10.0 → 3.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS-VERCEL-RESEARCH.md +23 -12
- package/README.md +81 -182
- package/agents/ti-pro.md +8 -14
- package/lib/cleanup.js +13 -0
- package/lib/commands/skills.js +2 -1
- package/lib/commands/update.js +4 -1
- package/lib/config.js +9 -11
- package/lib/platform.js +1 -1
- package/package.json +2 -3
- package/skills/purgetss/SKILL.md +12 -0
- package/skills/purgetss/references/animation-advanced.md +0 -9
- package/skills/purgetss/references/app-branding.md +20 -0
- package/skills/purgetss/references/appearance-module.md +85 -27
- package/skills/purgetss/references/apply-directive.md +60 -0
- package/skills/purgetss/references/arbitrary-values.md +41 -0
- package/skills/purgetss/references/cli-commands.md +52 -17
- package/skills/purgetss/references/custom-rules.md +36 -19
- package/skills/purgetss/references/customization-deep-dive.md +37 -15
- package/skills/purgetss/references/grid-layout.md +45 -26
- package/skills/purgetss/references/icon-fonts.md +27 -25
- package/skills/purgetss/references/installation-setup.md +28 -2
- package/skills/purgetss/references/ios-large-titles.md +31 -15
- package/skills/purgetss/references/multi-density-images.md +57 -0
- package/skills/purgetss/references/opacity-modifier.md +11 -2
- package/skills/purgetss/references/semantic-colors.md +44 -1
- package/skills/purgetss/references/tikit-components.md +1 -3
- package/skills/alloy-guides/SKILL.md +0 -190
- package/skills/alloy-guides/references/CLI_TASKS.md +0 -233
- package/skills/alloy-guides/references/CONCEPTS.md +0 -171
- package/skills/alloy-guides/references/CONTROLLERS.md +0 -279
- package/skills/alloy-guides/references/MODELS.md +0 -1214
- package/skills/alloy-guides/references/PURGETSS.md +0 -46
- package/skills/alloy-guides/references/VIEWS_DYNAMIC.md +0 -235
- package/skills/alloy-guides/references/VIEWS_STYLES.md +0 -375
- package/skills/alloy-guides/references/VIEWS_WITHOUT_CONTROLLERS.md +0 -102
- package/skills/alloy-guides/references/VIEWS_XML.md +0 -581
- package/skills/alloy-guides/references/WIDGETS.md +0 -160
- package/skills/alloy-howtos/SKILL.md +0 -181
- package/skills/alloy-howtos/references/best_practices.md +0 -121
- package/skills/alloy-howtos/references/cli_reference.md +0 -230
- package/skills/alloy-howtos/references/config_files.md +0 -158
- package/skills/alloy-howtos/references/custom_tags.md +0 -148
- package/skills/alloy-howtos/references/debugging_troubleshooting.md +0 -78
- package/skills/alloy-howtos/references/samples.md +0 -156
- package/skills/ti-api/SKILL.md +0 -109
- package/skills/ti-api/references/api-android.md +0 -675
- package/skills/ti-api/references/api-app-platform.md +0 -636
- package/skills/ti-api/references/api-core.md +0 -764
- package/skills/ti-api/references/api-data-network.md +0 -641
- package/skills/ti-api/references/api-media.md +0 -655
- package/skills/ti-api/references/api-modules-ble-bluetooth.md +0 -657
- package/skills/ti-api/references/api-modules-coremotion-urlsession.md +0 -411
- package/skills/ti-api/references/api-modules-map.md +0 -632
- package/skills/ti-api/references/api-modules-nfc.md +0 -725
- package/skills/ti-api/references/api-modules-social-misc.md +0 -526
- package/skills/ti-api/references/api-services.md +0 -700
- package/skills/ti-api/references/api-ui-android.md +0 -499
- package/skills/ti-api/references/api-ui-extras.md +0 -702
- package/skills/ti-api/references/api-ui-ios-animator.md +0 -378
- package/skills/ti-api/references/api-ui-ios.md +0 -756
- package/skills/ti-api/references/api-ui-lists.md +0 -581
- package/skills/ti-api/references/api-ui-text-input.md +0 -607
- package/skills/ti-api/references/api-ui-views.md +0 -572
- package/skills/ti-api/references/api-ui-windows-navigation.md +0 -676
- package/skills/ti-api/references/api-xml-global.md +0 -743
- package/skills/ti-guides/SKILL.md +0 -75
- package/skills/ti-guides/references/advanced-data-and-images.md +0 -155
- package/skills/ti-guides/references/android-manifest.md +0 -97
- package/skills/ti-guides/references/app-distribution.md +0 -373
- package/skills/ti-guides/references/application-frameworks.md +0 -366
- package/skills/ti-guides/references/cli-reference.md +0 -700
- package/skills/ti-guides/references/coding-best-practices.md +0 -150
- package/skills/ti-guides/references/commonjs-advanced.md +0 -279
- package/skills/ti-guides/references/hello-world.md +0 -99
- package/skills/ti-guides/references/hyperloop-native-access.md +0 -458
- package/skills/ti-guides/references/javascript-primer.md +0 -402
- package/skills/ti-guides/references/reserved-words.md +0 -36
- package/skills/ti-guides/references/resources.md +0 -172
- package/skills/ti-guides/references/style-and-conventions.md +0 -104
- package/skills/ti-guides/references/tiapp-config.md +0 -655
- package/skills/ti-howtos/SKILL.md +0 -143
- package/skills/ti-howtos/references/android-platform-deep-dives.md +0 -609
- package/skills/ti-howtos/references/automation-fastlane-appium.md +0 -96
- package/skills/ti-howtos/references/buffer-codec-streams.md +0 -162
- package/skills/ti-howtos/references/cross-platform-development.md +0 -358
- package/skills/ti-howtos/references/debugging-profiling.md +0 -473
- package/skills/ti-howtos/references/extending-titanium.md +0 -684
- package/skills/ti-howtos/references/google-maps-v2.md +0 -172
- package/skills/ti-howtos/references/ios-map-kit.md +0 -149
- package/skills/ti-howtos/references/ios-platform-deep-dives.md +0 -595
- package/skills/ti-howtos/references/local-data-sources.md +0 -310
- package/skills/ti-howtos/references/location-and-maps.md +0 -267
- package/skills/ti-howtos/references/media-apis.md +0 -268
- package/skills/ti-howtos/references/notification-services.md +0 -539
- package/skills/ti-howtos/references/remote-data-sources.md +0 -339
- package/skills/ti-howtos/references/tutorials.md +0 -552
- package/skills/ti-howtos/references/using-modules.md +0 -182
- package/skills/ti-howtos/references/web-content-integration.md +0 -288
- package/skills/ti-howtos/references/webpack-build-pipeline.md +0 -125
|
@@ -1,581 +0,0 @@
|
|
|
1
|
-
# Ti.UI Lists & Tables API Reference
|
|
2
|
-
|
|
3
|
-
## Ti.UI.ListView
|
|
4
|
-
> A list view is used to present information, organized in to sections and items, in a vertically-scrolling view.
|
|
5
|
-
> Extends Ti.UI.View
|
|
6
|
-
> Platforms: both
|
|
7
|
-
|
|
8
|
-
| Android | iOS |
|
|
9
|
-
| ------- | --- |
|
|
10
|
-
|  |  |
|
|
11
|
-
|
|
12
|
-
Use the <Titanium.UI.createListView> method or **`<ListView>`** Alloy element to create a `ListView`.
|
|
13
|
-
|
|
14
|
-
A `ListView` object is a container for [ListSection](Titanium.UI.ListSection)
|
|
15
|
-
objects that are, in turn, containers for [ListItem](Titanium.UI.ListItem) objects. This is
|
|
16
|
-
easily visualized as an Alloy view:
|
|
17
|
-
|
|
18
|
-
``` xml
|
|
19
|
-
|
|
20
|
-
### Properties (unique: 54/122)
|
|
21
|
-
| Property | Type | Default | Platform | Description |
|
|
22
|
-
|----------|------|---------|----------|-------------|
|
|
23
|
-
| touchFeedback | Boolean | true | android | A material design visual construct that provides an instantaneous visual confir… |
|
|
24
|
-
| allowsSelection | Boolean | true | ios | Determines whether this item can be selected. |
|
|
25
|
-
| canScroll | Boolean | true | both | Determines if the list view can scroll in response to user actions. |
|
|
26
|
-
| contentOffset | Point | — | android | X and Y coordinates to which to reposition the top-left point of the content re… |
|
|
27
|
-
| disableBounce | Boolean | false | ios | Determines whether the scroll-bounce of the list view should be disabled. |
|
|
28
|
-
| editing | Boolean | false | both | Determines if the list view is currently in editing mode. |
|
|
29
|
-
| requiresEditingToMove | Boolean | true | both | Determines if the list view should allow drag-and-drop even without going into … |
|
|
30
|
-
| fastScroll | Boolean | false | android | Sets the fastScroll mode on Android ListViews. |
|
|
31
|
-
| fixedSize | Boolean | false | android | Sets fixedSize mode on Android ListViews. |
|
|
32
|
-
| allowsSelectionDuringEditing | Boolean | false | both | Determines whether this list view items can be selected while editing the table. |
|
|
33
|
-
| allowsMultipleSelectionDuringEditing | Boolean | false | both | Determines whether multiple items of this list view can be selected at the same… |
|
|
34
|
-
| allowsMultipleSelectionInteraction | Boolean | false | both | Allows a two-finger pan gesture to automatically transition the table view into… |
|
|
35
|
-
| lazyLoadingEnabled | Boolean | true | ios | Determines if the list view should use lazy loading to load remote images. |
|
|
36
|
-
| pruneSectionsOnEdit | Boolean | false | ios | Determines if empty sections are retained when the user completes editing the l… |
|
|
37
|
-
| templates | Dictionary | — | both | Contain key-value pairs mapping a style name (key) to an <ItemTemplate> (value). |
|
|
38
|
-
| sections | Array<Titanium.UI.ListSection> | — | both | Sections of this list. |
|
|
39
|
-
| defaultItemTemplate | String \| Number | Titanium.UI.LIST_ITEM_TEMPLATE_DEFAULT | both | Sets the default template for list data items that do not specify the `template… |
|
|
40
|
-
| separatorHeight | String \| Number | — | android | height of the ListView separator. |
|
|
41
|
-
| footerDividersEnabled | Boolean | undefined but behaves as false | android | When set to false, the ListView will not draw the divider before the footer vie… |
|
|
42
|
-
| footerTitle | String | — | both | List view footer title. |
|
|
43
|
-
| footerView | Ti.UI.View | — | both | List view footer as a view that will be rendered instead of a label. |
|
|
44
|
-
| headerDividersEnabled | Boolean | undefined but behaves as false | android | When set to false, the ListView will not draw the divider after the header view. |
|
|
45
|
-
| headerTitle | String | — | both | List view header title. |
|
|
46
|
-
| headerView | Ti.UI.View | — | both | List view header as a view that will be rendered instead of a label. |
|
|
47
|
-
| pullView | Ti.UI.View | — | ios | View positioned above the first row that is only revealed when the user drags t… |
|
|
48
|
-
| refreshControl | Ti.UI.RefreshControl | — | both | View positioned above the first row that is only revealed when the user drags t… |
|
|
49
|
-
| searchView | Ti.UI.SearchBar \| Ti.UI.Android.SearchView | — | both | Search field to use for the list view. |
|
|
50
|
-
| searchText | String | — | both | The string to use as the search parameter. |
|
|
51
|
-
| caseInsensitiveSearch | Boolean | true | both | Determines if the search performed is case insensitive. |
|
|
52
|
-
| continuousUpdate | Boolean | false | both | Determines if the scrolling event should fire every time there is a new visible… |
|
|
53
|
-
| forceUpdates | Boolean | false | both | Optimize the `continuousUpdate` scrolling event. |
|
|
54
|
-
| keepSectionsInSearch | Boolean | false | ios | Determines if the section information is displayed in the search results when u… |
|
|
55
|
-
| keyboardDismissMode | Number | Undefined (behaves like <Titanium.UI.iOS.KEYBOARD_DISMISS_MODE_NONE>) | ios | The manner in which the keyboard is dismissed when a drag begins in the list vi… |
|
|
56
|
-
| sectionIndexTitles | Array<ListViewIndexEntry> | — | ios | Array of objects (with `title` and `index` properties) to control the list view… |
|
|
57
|
-
| scrollIndicatorStyle | Number | <Titanium.UI.iOS.ScrollIndicatorStyle.DEFAULT> | ios | Style of the scrollbar. |
|
|
58
|
-
| willScrollOnStatusTap | Boolean | true | ios | Controls the scroll-to-top gesture. |
|
|
59
|
-
| sectionCount | Number | — | both | Number of sections in this list view. |
|
|
60
|
-
| sectionHeaderTopPadding | Number | — | ios | Padding above each section header. |
|
|
61
|
-
| showSelectionCheck | Boolean | true | android | Determines whether the selection checkmark is displayed on selected items. |
|
|
62
|
-
| showVerticalScrollIndicator | Boolean | true | both | Determines whether this list view displays a vertical scroll indicator. |
|
|
63
|
-
| separatorColor | String \| Ti.UI.Color | platform-specific default color | both | Separator line color between items, as a color name or hex triplet. |
|
|
64
|
-
| separatorInsets | HorizontalInsets | — | ios | The insets for list view separators (applies to all cells). |
|
|
65
|
-
| separatorStyle | Number | — | both | Separator style constant. |
|
|
66
|
-
| style | Number | Titanium.UI.iOS.ListViewStyle.PLAIN | ios | Style of the list view. |
|
|
67
|
-
| tableSeparatorInsets | HorizontalInsets | — | ios | The insets for the table view header and footer. |
|
|
68
|
-
| listSeparatorInsets | HorizontalInsets | — | ios | The insets for the list view header and footer. |
|
|
69
|
-
| rowSeparatorInsets | HorizontalInsets | — | ios | The insets for list view cells (applies to all cells). |
|
|
70
|
-
| dimBackgroundForSearch | Boolean | true | ios | A Boolean indicating whether the underlying content is dimmed during a search. |
|
|
71
|
-
| showSearchBarInNavBar | Boolean | false | ios | A Boolean indicating whether search bar will be in navigation bar. |
|
|
72
|
-
| resultsBackgroundColor | String \| Ti.UI.Color | undefined (behaves as white) | ios | The background color of the search results (iOS-only). |
|
|
73
|
-
| resultsSeparatorColor | String \| Ti.UI.Color | undefined (behaves as gray) | ios | Separator line color between rows inside search results, as a color name or hex… |
|
|
74
|
-
| resultsSeparatorStyle | Number | — | ios | The separator style of the search results (iOS-only). |
|
|
75
|
-
| resultsSeparatorInsets | HorizontalInsets | — | ios | The insets for search results separators (applies to all cells & iOS-only). |
|
|
76
|
-
| selectedItems | Array<ListItemEventType> | — | both | Returns the selected list view items. |
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
### Methods (11)
|
|
80
|
-
| Method | Returns | Platform | Description |
|
|
81
|
-
|--------|---------|----------|-------------|
|
|
82
|
-
| scrollToItem(sectionIndex, itemIndex, animation) | void | both | Scrolls to a specific item. |
|
|
83
|
-
| deselectItem(sectionIndex, itemIndex) | void | ios | Deselects a specific item. |
|
|
84
|
-
| appendSection(section, animation) | void | both | Appends a single section or an array of sections to the end of the list. |
|
|
85
|
-
| deleteSectionAt(sectionIndex, animation) | void | both | Deletes an existing section. |
|
|
86
|
-
| insertSectionAt(sectionIndex, section, animation) | void | both | Inserts a section or an array of sections at a specific index. |
|
|
87
|
-
| replaceSectionAt(sectionIndex, section, animation) | void | both | Replaces an existing section. |
|
|
88
|
-
| selectItem(sectionIndex, itemIndex) | void | ios | Selects an item in the list using the specified item and section indices. |
|
|
89
|
-
| setContentInsets(edgeInsets, options) | void | ios | Sets this list view's content insets. |
|
|
90
|
-
| setContentOffset(contentOffset, options) | void | both | Sets the value of the content offset of the list view without animation by defa… |
|
|
91
|
-
| setMarker(markerProps) | void | both | Sets a reference item in the list view. |
|
|
92
|
-
| addMarker(markerProps) | void | both | Adds a reference item in the list view. |
|
|
93
|
-
|
|
94
|
-
### Events (20)
|
|
95
|
-
| Event | Platform | Description |
|
|
96
|
-
|-------|----------|-------------|
|
|
97
|
-
| indexclick | ios | Fired when the index bar is clicked by the user. |
|
|
98
|
-
| itemclick | both | Fired when a list row is clicked by the user. |
|
|
99
|
-
| itemsselected | both | Fired when user stops two-pan gesture interaction for selecting multiple items.… |
|
|
100
|
-
| delete | both | Fired when a list row is deleted by the user. |
|
|
101
|
-
| insert | ios | Fired when a list row is inserted by the user. |
|
|
102
|
-
| dragstart | ios | Fired when the user starts dragging the list view. |
|
|
103
|
-
| dragend | ios | Fired when the user stops dragging the list view. |
|
|
104
|
-
| marker | both | Fired when the list view displays the reference item. |
|
|
105
|
-
| movestart | both | Fired when a list row has started moving. |
|
|
106
|
-
| moveend | both | Fired when a list row has ended moving. |
|
|
107
|
-
| move | both | Fired when a list row is moved to a different location by the user. |
|
|
108
|
-
| noresults | both | Fired when the search using either [searchView](Titanium.UI.ListView.searchView… |
|
|
109
|
-
| pull | ios | Fired when the user drags the list view past the top edge of the [pullView](Tit… |
|
|
110
|
-
| prefetch | ios | Fired when new list items are prefetched. The items are ordered ascending by ge… |
|
|
111
|
-
| cancelprefetch | ios | Fired when list items that previously were considered as candidates for pre-fet… |
|
|
112
|
-
| pullend | ios | Fired when the user stops dragging the list view and the [pullView](Titanium.UI… |
|
|
113
|
-
| editaction | ios | Fired when the user interacts with one of the custom edit actions defined by <T… |
|
|
114
|
-
| scrollstart | both | Fires when the list view starts scrolling by user interaction. Calling the `scr… |
|
|
115
|
-
| scrollend | both | Fires when the list view ends scrolling. Calling the `scrollTo` methods will no… |
|
|
116
|
-
| scrolling | both | Fires when the list view is scrolling. Calling the `scrollTo` methods will not … |
|
|
117
|
-
|
|
118
|
-
### Related Types
|
|
119
|
-
|
|
120
|
-
#### AnimatedOptions
|
|
121
|
-
> A JavaScript object holding an `animated` property. Used for many UI methods as a means of specifying some transition should be animated.
|
|
122
|
-
|
|
123
|
-
| Property | Type | Description |
|
|
124
|
-
|----------|------|-------------|
|
|
125
|
-
| animated | Boolean | If `true`, animate a transition for the method/value change. Note that for most… |
|
|
126
|
-
|
|
127
|
-
#### AnimatedWithDurationOptions
|
|
128
|
-
> A JavaScript object holding `animated` and `duration` properties. Used on iOS For [TableView](Titanium.UI.TableView) and [ListView](Titanium.UI.ListView) content offset transitions.
|
|
129
|
-
|
|
130
|
-
| Property | Type | Description |
|
|
131
|
-
|----------|------|-------------|
|
|
132
|
-
| animated | Boolean | If `true`, animate a transition for the method/value change. Note that for most… |
|
|
133
|
-
| duration | Number | The duration in `milliseconds` for animation |
|
|
134
|
-
|
|
135
|
-
#### Dictionary
|
|
136
|
-
> Plain JavaScript object.
|
|
137
|
-
|
|
138
|
-
*Plus 6 more types: ListViewMarkerProps, Padding, Point, SelectedItem*
|
|
139
|
-
|
|
140
|
-
---
|
|
141
|
-
|
|
142
|
-
## Ti.UI.ListItem
|
|
143
|
-
> A list item is an individual item in a list section.
|
|
144
|
-
> Extends Ti.Proxy
|
|
145
|
-
> Platforms: both
|
|
146
|
-
|
|
147
|
-
A list item is a combination of a <ListDataItem> and <ItemTemplate>. The list data item
|
|
148
|
-
represents the actual data, while the item template represents the style elements of the item.
|
|
149
|
-
|
|
150
|
-
You should not create `ListItem` objects with a JavaScript factory method, as you do other Titanium proxies.
|
|
151
|
-
Instead, you should pass a <ListDataItem> array to the `setItems` method of a `ListSection`. The list data items
|
|
152
|
-
contain the data you want to display in the list.
|
|
153
|
-
|
|
154
|
-
Alloy applications can use **`<ListItem>`** elements to create `ListItem` objects. `<ListItem>` elements
|
|
155
|
-
must be nested inside a **`<ListSection>`** element, which itself is nested in a `<ListView>` element,
|
|
156
|
-
as shown below:
|
|
157
|
-
|
|
158
|
-
``` xml
|
|
159
|
-
|
|
160
|
-
### Properties (unique: 26/28)
|
|
161
|
-
| Property | Type | Default | Platform | Description |
|
|
162
|
-
|----------|------|---------|----------|-------------|
|
|
163
|
-
| itemId | String | — | both | A user defined string that gets passed to events. |
|
|
164
|
-
| accessoryType | Number | Titanium.UI.LIST_ACCESSORY_TYPE_NONE | both | Sets an accessory on the right side of an item. |
|
|
165
|
-
| backgroundColor | String \| Ti.UI.Color | Transparent | both | Background color of the view, as a color name or hex triplet. |
|
|
166
|
-
| backgroundImage | String | — | both | Background image to render when the item is not selected. |
|
|
167
|
-
| backgroundGradient | Gradient | — | both | Background gradient to render when the item is not selected. |
|
|
168
|
-
| backgroundSelectedColor | String \| Ti.UI.Color | transparent | both | Background color of the view, as a color name or hex triplet when item is selec… |
|
|
169
|
-
| backgroundSelectedImage | String | — | both | Background image to render when the item is selected. |
|
|
170
|
-
| backgroundSelectedGradient | Gradient | — | ios | Background gradient to render when the item is selected. |
|
|
171
|
-
| selectedBackgroundColor | String \| Ti.UI.Color | transparent | both | Background color of the view, as a color name or hex triplet when item is selec… |
|
|
172
|
-
| selectedBackgroundImage | String | — | both | Background image to render when the item is selected. |
|
|
173
|
-
| selectedBackgroundGradient | Gradient | — | ios | Background gradient to render when the item is selected. |
|
|
174
|
-
| canEdit | Boolean | false | both | Specifies if the item can be deleted by a user initiated action. |
|
|
175
|
-
| canInsert | Boolean | false | ios | Specifies if the item can be inserted by a user initiated action. |
|
|
176
|
-
| canMove | Boolean | false | both | Specifies if the item can be reordered within the list view by a user initiated… |
|
|
177
|
-
| editActions | Array<RowActionType> | — | ios | Specifies custom action items to be shown when when a list item is edited. |
|
|
178
|
-
| searchableText | String | — | both | The text to match against when the [ListView](Titanium.UI.ListView) is performi… |
|
|
179
|
-
| color | String \| Ti.UI.Color | — | both | Default text color of the item when not selected, as a color name or hex triple… |
|
|
180
|
-
| subtitleColor | String \| Ti.UI.Color | — | ios | Default text color of the subtitle, as a color name or hex triplet. |
|
|
181
|
-
| selectedColor | String \| Ti.UI.Color | — | ios | Color to use for the item title when the item is selected, as a color name or h… |
|
|
182
|
-
| selectedSubtitleColor | String \| Ti.UI.Color | — | ios | Color to use for the item subtitle when the item is selected, as a color name o… |
|
|
183
|
-
| font | Font | System default font. | both | Font to use for the item title. |
|
|
184
|
-
| height | Number \| String | — | both | Row height in platform-specific units. |
|
|
185
|
-
| image | String | — | both | Image to render in the image area of the item, specified as a local path or URL. |
|
|
186
|
-
| title | String | — | both | Title to set in the text area of the item. |
|
|
187
|
-
| selectionStyle | Number | — | both | Selection style constant to control the selection color. |
|
|
188
|
-
| subtitle | String | — | ios | Subtitle to set in the text area of the item. |
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
### Related Types
|
|
194
|
-
|
|
195
|
-
#### Font
|
|
196
|
-
> An abstract datatype for specifying a text font.
|
|
197
|
-
|
|
198
|
-
| Property | Type | Description |
|
|
199
|
-
|----------|------|-------------|
|
|
200
|
-
| fontFamily | String | Specifies the font family or specific font to use. |
|
|
201
|
-
| fontSize | Number \| String | Font size, in platform-dependent units. |
|
|
202
|
-
| fontWeight | String | Font weight. Valid values are "bold", "semibold", "normal", "thin", "light" and… |
|
|
203
|
-
| fontStyle | String | Font style. Valid values are "italic" or "normal". |
|
|
204
|
-
| textStyle | String | The text style for the font. |
|
|
205
|
-
|
|
206
|
-
#### Gradient
|
|
207
|
-
> A simple object defining a color gradient.
|
|
208
|
-
|
|
209
|
-
| Property | Type | Description |
|
|
210
|
-
|----------|------|-------------|
|
|
211
|
-
| type | String | Type of gradient, either 'linear' or 'radial'. |
|
|
212
|
-
| startPoint | Point | Start point for the gradient. |
|
|
213
|
-
| endPoint | Point | End point for the gradient. |
|
|
214
|
-
| startRadius | Number | For a radial gradient, the radius at the `startPoint`. |
|
|
215
|
-
| endRadius | Number | For a radial gradient, the radius at the `endPoint`. |
|
|
216
|
-
| colors | Array<String> \| Array<GradientColorRef> | An array of colors, as a color name or hex triplet. |
|
|
217
|
-
| backfillStart | Boolean | Set to `true` to continue filling with the starting color beyond the `startPoin… |
|
|
218
|
-
| backfillEnd | Boolean | Set to `true` to continue filling with the final color beyond the `endPoint`. |
|
|
219
|
-
|
|
220
|
-
---
|
|
221
|
-
|
|
222
|
-
## Ti.UI.ListSection
|
|
223
|
-
> A list section is a container within a list view used to organize list items.
|
|
224
|
-
> Extends Ti.Proxy
|
|
225
|
-
> Platforms: both
|
|
226
|
-
|
|
227
|
-
Use the <Titanium.UI.createListSection> method or **`<ListSection>`** Alloy element to create a `ListSection`.
|
|
228
|
-
|
|
229
|
-
List sections are used to manipulate and organize list items contained within it. For examples
|
|
230
|
-
of using list sections, see the examples in <Titanium.UI.ListView> and <Titanium.UI.ListItem>.
|
|
231
|
-
|
|
232
|
-
### Properties (unique: 7/9)
|
|
233
|
-
| Property | Type | Default | Platform | Description |
|
|
234
|
-
|----------|------|---------|----------|-------------|
|
|
235
|
-
| footerTitle | String | — | both | Title of this section footer. |
|
|
236
|
-
| footerView | Ti.UI.View | — | both | View to use for this section footer. |
|
|
237
|
-
| headerTitle | String | — | both | Title of this section header. |
|
|
238
|
-
| headerView | Ti.UI.View | — | both | View to use for this section header. |
|
|
239
|
-
| items | Array<ListDataItem> | — | both | Items of this list section. |
|
|
240
|
-
| itemCount | Number | — | both | Returns the item count of the section. |
|
|
241
|
-
| filteredItemCount | Number | — | android | Returns the item count of the section, also incorporating the search filter if … |
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
### Methods (7)
|
|
245
|
-
| Method | Returns | Platform | Description |
|
|
246
|
-
|--------|---------|----------|-------------|
|
|
247
|
-
| setItems(dataItems, animation) | void | both | Sets the data entries in the list section. |
|
|
248
|
-
| appendItems(dataItems, animation) | void | both | Appends the data entries to the end of the list section. |
|
|
249
|
-
| insertItemsAt(itemIndex, dataItems, animation) | void | both | Inserts data entries to the list section at the specified index. |
|
|
250
|
-
| replaceItemsAt(index, count, dataItems, animation) | void | both | Removes count entries from the list section at the specified index, then insert… |
|
|
251
|
-
| deleteItemsAt(itemIndex, count, animation) | void | both | Removes count entries from the list section at the specified index. |
|
|
252
|
-
| getItemAt(itemIndex) | ListDataItem | both | Returns the item entry from the list view at the specified index. |
|
|
253
|
-
| updateItemAt(index, dataItem, animation) | void | both | Updates an item at the specified index. |
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
### Related Types
|
|
257
|
-
|
|
258
|
-
#### ListDataItem
|
|
259
|
-
> Represents displayed item data.
|
|
260
|
-
|
|
261
|
-
| Property | Type | Description |
|
|
262
|
-
|----------|------|-------------|
|
|
263
|
-
| template | String \| Number | Template ID configured with the <Titanium.UI.ListView.templates> property or <T… |
|
|
264
|
-
| properties | Dictionary<Titanium.UI.ListItem> | Contains key-value pairs of view properties and their values that are applied t… |
|
|
265
|
-
|
|
266
|
-
#### ListViewAnimationProperties
|
|
267
|
-
> A simple object for specifying the animation properties to use when inserting or deleting sections or cells, or scrolling the list.
|
|
268
|
-
|
|
269
|
-
| Property | Type | Description |
|
|
270
|
-
|----------|------|-------------|
|
|
271
|
-
| animated | Boolean | Whether this list change should be animated. Ignored if any `animationStyle` va… |
|
|
272
|
-
| animationStyle | Number | Type of animation to use for cell insertions and deletions. |
|
|
273
|
-
| position | Number | Specifies what position to scroll the selected cell to. |
|
|
274
|
-
|
|
275
|
-
---
|
|
276
|
-
|
|
277
|
-
## Ti.UI.ListViewScrollPosition
|
|
278
|
-
> A set of constants for the position value that can be used for the `position` property of <ListViewAnimationProperties> when invoking the ListView's `scrollToItem`, `appendSection`, `deleteSectionAt`, `insertSectionAt` and `replaceSectionAt` methods.
|
|
279
|
-
> Extends Ti.Proxy
|
|
280
|
-
> Platforms: both
|
|
281
|
-
|
|
282
|
-
### Constants (4)
|
|
283
|
-
- **OTHER_\***: BOTTOM, MIDDLE, NONE, TOP
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
---
|
|
289
|
-
|
|
290
|
-
## Ti.UI.TableView
|
|
291
|
-
> A table view is used to present information, organized in sections and rows, in a vertically-scrolling view.
|
|
292
|
-
> Extends Ti.UI.View
|
|
293
|
-
> Platforms: both
|
|
294
|
-
|
|
295
|
-
| Android | iOS |
|
|
296
|
-
| ------- | --- |
|
|
297
|
-
|  |  |
|
|
298
|
-
|
|
299
|
-
A `TableView` object is a container for [TableViewSection](Titanium.UI.TableViewSection)
|
|
300
|
-
objects that are, in turn, containers for [TableViewRow](Titanium.UI.TableViewRow) objects.
|
|
301
|
-
|
|
302
|
-
Use the <Titanium.UI.createTableView> method or **`<TableView>`** Alloy element to create a `TableView`.
|
|
303
|
-
|
|
304
|
-
Also see the [TableViews guide](https://titaniumsdk.com/guide/Titanium_SDK/Titanium_SDK_How-tos/User_Interface_Deep_Dives/TableViews.html).
|
|
305
|
-
|
|
306
|
-
### Creating Tables
|
|
307
|
-
|
|
308
|
-
There are few approaches to creating and using `TableView` object.
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
*(See full overview in titanium-docs)*
|
|
312
|
-
|
|
313
|
-
### Properties (unique: 55/122)
|
|
314
|
-
| Property | Type | Default | Platform | Description |
|
|
315
|
-
|----------|------|---------|----------|-------------|
|
|
316
|
-
| backgroundColor | String \| Ti.UI.Color | transparent on non-iOS platforms, white on the iOS platform | both | Background color of the view, as a color name or hex triplet. |
|
|
317
|
-
| touchFeedback | Boolean | true | android | A material design visual construct that provides an instantaneous visual confir… |
|
|
318
|
-
| allowsSelection | Boolean | true | ios | Determines whether this table's rows can be selected. |
|
|
319
|
-
| allowsSelectionDuringEditing | Boolean | false | both | Determines whether this table's rows can be selected while editing the table. |
|
|
320
|
-
| contentOffset | Point | — | android | X and Y coordinates to which to reposition the top-left point of the content re… |
|
|
321
|
-
| data | Array<Titanium.UI.TableViewRow> \| Array<Titanium.UI.TableViewSection> | — | both | Rows of the table view. |
|
|
322
|
-
| editable | Boolean | Depends on `editing` and `moving` mode | both | Determines the rows' default editable behavior, which allows them to be deleted… |
|
|
323
|
-
| editing | Boolean | false | both | Determines whether row editing mode is active. |
|
|
324
|
-
| filterAttribute | String | — | both | Filter attribute to be used when searching. |
|
|
325
|
-
| filterAnchored | Boolean | false | both | Determines whether the search is limited to the start of the string |
|
|
326
|
-
| filterCaseInsensitive | Boolean | true | both | Determines whether the search is case insensitive. |
|
|
327
|
-
| fixedSize | Boolean | false | android | Sets fixedSize mode on Android TableView. |
|
|
328
|
-
| footerDividersEnabled | Boolean | undefined but behaves as false | android | When set to false, the ListView will not draw the divider before the footer vie… |
|
|
329
|
-
| footerTitle | String | — | both | Table view footer title. |
|
|
330
|
-
| maxClassname | Number | 32 | android | Max number of row class names. |
|
|
331
|
-
| headerPullView | Ti.UI.View | — | ios | View positioned above the first row that is only revealed when the user drags t… |
|
|
332
|
-
| refreshControl | Ti.UI.RefreshControl | — | both | View positioned above the first row that is only revealed when the user drags t… |
|
|
333
|
-
| hideSearchOnSelection | Boolean | true | ios | Determines whether the search field should hide on completion. |
|
|
334
|
-
| allowsMultipleSelectionDuringEditing | Boolean | false | both | Determines whether multiple items of this table view can be selected at the sam… |
|
|
335
|
-
| allowsMultipleSelectionInteraction | Boolean | false | ios | Allows a two-finger pan gesture to automatically transition the table view into… |
|
|
336
|
-
| footerView | Ti.UI.View | — | both | Table view footer as a view that will be rendered instead of a label. |
|
|
337
|
-
| headerDividersEnabled | Boolean | undefined but behaves as false | android | When set to false, the ListView will not draw the divider after the header view. |
|
|
338
|
-
| headerTitle | String | — | both | Table view header title. |
|
|
339
|
-
| headerView | Ti.UI.View | — | both | Table view header as a view that will be rendered instead of a label. |
|
|
340
|
-
| index | Array<TableViewIndexEntry> | — | ios | Array of objects (with `title` and `index` properties) to control the table vie… |
|
|
341
|
-
| maxRowHeight | Number | — | both | Maximum row height for table view rows. |
|
|
342
|
-
| minRowHeight | Number | — | both | Minimum row height for table view rows. |
|
|
343
|
-
| moveable | Boolean | Depends on `editing` and `moving` mode | both | Determines the rows' default moveable behavior, which allows them to be re-orde… |
|
|
344
|
-
| moving | Boolean | false | both | Determines whether row moving mode is active. |
|
|
345
|
-
| overScrollMode | Number | Titanium.UI.Android.OVER_SCROLL_ALWAYS | android | Determines the behavior when the user overscrolls the view. |
|
|
346
|
-
| rowHeight | Number | — | both | Default row height for table view rows. |
|
|
347
|
-
| scrollable | Boolean | true | both | If `true`, the table view can be scrolled. |
|
|
348
|
-
| scrollIndicatorStyle | Number | <Titanium.UI.iOS.ScrollIndicatorStyle.DEFAULT> | ios | Style of the scrollbar. |
|
|
349
|
-
| scrollsToTop | Boolean | true | ios | Controls whether the scroll-to-top gesture is effective. |
|
|
350
|
-
| search | Ti.UI.SearchBar \| Ti.UI.Android.SearchView | — | both | Search field to use for the table view. |
|
|
351
|
-
| dimBackgroundForSearch | Boolean | true | ios | A Boolean indicating whether the underlying content is dimmed during a search. |
|
|
352
|
-
| keyboardDismissMode | Number | Undefined (behaves like <Titanium.UI.iOS.KEYBOARD_DISMISS_MODE_NONE>) | ios | The manner in which the keyboard is dismissed when a drag begins in the table v… |
|
|
353
|
-
| showSearchBarInNavBar | Boolean | false | ios | A Boolean indicating whether search bar will be in navigation bar. |
|
|
354
|
-
| searchAsChild | Boolean | true | android | Determines whether the [SearchBar](Titanium.UI.SearchBar) or [SearchView](Titan… |
|
|
355
|
-
| searchHidden | Boolean | false (search field visible) | ios | Determines whether the search field is visible. |
|
|
356
|
-
| sectionCount | Number | — | both | Number of sections in this table view. |
|
|
357
|
-
| sections | Array<Titanium.UI.TableViewSection> | — | both | Sections of this table. |
|
|
358
|
-
| sectionHeaderTopPadding | Number | — | ios | Padding above each section header. |
|
|
359
|
-
| separatorColor | String \| Ti.UI.Color | platform-specific default color | both | Separator line color between rows, as a color name or hex triplet. |
|
|
360
|
-
| separatorInsets | HorizontalInsets | — | ios | The insets for table view separators (applies to all cells). |
|
|
361
|
-
| tableSeparatorInsets | HorizontalInsets | — | ios | The insets for the table view header and footer. |
|
|
362
|
-
| rowSeparatorInsets | HorizontalInsets | — | ios | The insets for table view cells (applies to all cells). |
|
|
363
|
-
| separatorStyle | Number | — | both | Separator style constant. |
|
|
364
|
-
| showSelectionCheck | Boolean | true | android | Determines whether the selection checkmark is displayed on selected rows. |
|
|
365
|
-
| showVerticalScrollIndicator | Boolean | true | ios | Determines whether this table view displays a vertical scroll indicator. |
|
|
366
|
-
| style | Number | — | ios | Style of the table view, specified using one of the constants from <Titanium.UI… |
|
|
367
|
-
| resultsBackgroundColor | String \| Ti.UI.Color | undefined (behaves as white) | ios | The background color of the search results (iOS-only). |
|
|
368
|
-
| resultsSeparatorColor | String \| Ti.UI.Color | undefined (behaves as gray) | ios | Separator line color between rows inside search results, as a color name or hex… |
|
|
369
|
-
| resultsSeparatorStyle | Number | — | ios | The separator style of the search results (iOS-only). |
|
|
370
|
-
| resultsSeparatorInsets | HorizontalInsets | — | ios | The insets for search results separators (applies to all cells & iOS-only). |
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
### Methods (18)
|
|
374
|
-
| Method | Returns | Platform | Description |
|
|
375
|
-
|--------|---------|----------|-------------|
|
|
376
|
-
| appendRow(row, animation) | void | both | Appends a single row or an array of rows to the end of the table. |
|
|
377
|
-
| appendSection(section, animation) | void | both | Appends a single section or an array of sections to the end of the table. |
|
|
378
|
-
| deleteRow(row, animation) | void | both | Deletes an existing row. |
|
|
379
|
-
| deleteSection(section, animation) | void | both | Deletes an existing section. |
|
|
380
|
-
| deselectRow(row) | void | ios | Programmatically deselects a row. |
|
|
381
|
-
| insertRowAfter(index, row, animation) | void | both | Inserts a row after another row. |
|
|
382
|
-
| insertSectionAfter(index, section, animation) | void | both | Inserts a section after another section. |
|
|
383
|
-
| insertRowBefore(index, row, animation) | void | both | Inserts a row before another row. |
|
|
384
|
-
| insertSectionBefore(index, section, animation) | void | both | Inserts a section before another section. |
|
|
385
|
-
| scrollToIndex(index, animation) | void | both | Scrolls the table view to ensure that the specified row is on screen. |
|
|
386
|
-
| scrollToTop(top, animation) | void | both | Scrolls the table to a specific top position where 0 is the topmost y position … |
|
|
387
|
-
| setContentInsets(edgeInsets, options) | void | ios | Sets this tableview's content insets. |
|
|
388
|
-
| setContentOffset(contentOffset, options) | void | both | Sets the value of the content offset of the table view without animation by def… |
|
|
389
|
-
| selectRow(row) | void | both | Programmatically selects a row. In Android, it sets the currently selected item… |
|
|
390
|
-
| setData(data, animation) | void | both | Sets the data in the table. |
|
|
391
|
-
| setHeaderPullView(view) | void | ios | Sets the value of the [Titanium.UI.TableView.headerPullView] property. |
|
|
392
|
-
| updateRow(index, row, animation) | void | both | Updates an existing row, optionally with animation. |
|
|
393
|
-
| updateSection(index, section, animation) | void | both | Updates an existing section, optionally with animation. |
|
|
394
|
-
|
|
395
|
-
### Events (18)
|
|
396
|
-
| Event | Platform | Description |
|
|
397
|
-
|-------|----------|-------------|
|
|
398
|
-
| click | both | Fired when a table row is clicked by the user. |
|
|
399
|
-
| doubletap | both | Fired when the device detects a double tap against this view. |
|
|
400
|
-
| longpress | both | Fired when the device detects a long press. |
|
|
401
|
-
| singletap | both | Fired when the device detects a single tap against the view. |
|
|
402
|
-
| swipe | both | Fired when the device detects a swipe gesture (left or right) against the view. |
|
|
403
|
-
| touchcancel | ios | Fired when a touch gesture is interrupted by the device. |
|
|
404
|
-
| touchend | both | Fired when a touch gesture is complete. |
|
|
405
|
-
| touchstart | both | Fired as soon as the device detects a touch gesture against this view. |
|
|
406
|
-
| twofingertap | ios | Fired when the device detects a two-finger tap against the view. |
|
|
407
|
-
| rowsselected | both | Fired when user stops two-pan gesture interaction for selecting multiple rows. … |
|
|
408
|
-
| delete | both | Fired when a table row is deleted by the user. |
|
|
409
|
-
| indexclick | ios | Fired when the index bar is clicked by the user. |
|
|
410
|
-
| move | both | Fired when a table row is moved by the user. |
|
|
411
|
-
| scroll | both | Fired when the table view is scrolled. |
|
|
412
|
-
| scrollend | both | Fired when the table view stops scrolling. |
|
|
413
|
-
| dragstart | ios | Fired when the scrollable region starts being dragged. |
|
|
414
|
-
| dragend | ios | Fired when the scrollable region stops being dragged. |
|
|
415
|
-
| editaction | ios | Fired when the user interacts with one of the custom edit actions defined by <T… |
|
|
416
|
-
|
|
417
|
-
### Related Types
|
|
418
|
-
|
|
419
|
-
#### AnimatedOptions
|
|
420
|
-
> A JavaScript object holding an `animated` property. Used for many UI methods as a means of specifying some transition should be animated.
|
|
421
|
-
|
|
422
|
-
| Property | Type | Description |
|
|
423
|
-
|----------|------|-------------|
|
|
424
|
-
| animated | Boolean | If `true`, animate a transition for the method/value change. Note that for most… |
|
|
425
|
-
|
|
426
|
-
#### AnimatedWithDurationOptions
|
|
427
|
-
> A JavaScript object holding `animated` and `duration` properties. Used on iOS For [TableView](Titanium.UI.TableView) and [ListView](Titanium.UI.ListView) content offset transitions.
|
|
428
|
-
|
|
429
|
-
| Property | Type | Description |
|
|
430
|
-
|----------|------|-------------|
|
|
431
|
-
| animated | Boolean | If `true`, animate a transition for the method/value change. Note that for most… |
|
|
432
|
-
| duration | Number | The duration in `milliseconds` for animation |
|
|
433
|
-
|
|
434
|
-
#### HorizontalInsets
|
|
435
|
-
> Dictionary object of parameters for horizontal-only insets applied to [Table](Titanium.UI.TableView) and [List](Titanium.UI.ListView) views. Only `left` and `right` properties are used (see <Padding>).
|
|
436
|
-
|
|
437
|
-
| Property | Type | Description |
|
|
438
|
-
|----------|------|-------------|
|
|
439
|
-
| left | Number | Left padding/inset |
|
|
440
|
-
| right | Number | Right padding/inset |
|
|
441
|
-
|
|
442
|
-
*Plus 5 more types: SelectedRowObject, Size, TableViewAnimationProperties*
|
|
443
|
-
|
|
444
|
-
---
|
|
445
|
-
|
|
446
|
-
## Ti.UI.TableViewRow
|
|
447
|
-
> A table view row is an individual item in a table, organized into table view sections.
|
|
448
|
-
> Extends Ti.UI.View
|
|
449
|
-
> Platforms: both
|
|
450
|
-
|
|
451
|
-
Use the <Titanium.UI.createTableViewRow> method or **`<TableViewRow>`** Alloy element to create
|
|
452
|
-
a table view row.
|
|
453
|
-
|
|
454
|
-
These may be explicitly added to [TableViewSection](Titanium.UI.TableViewSection) objects, which are applied
|
|
455
|
-
to a [TableView](Titanium.UI.TableView). If a table section is not specified, one will be
|
|
456
|
-
automatically created.
|
|
457
|
-
|
|
458
|
-
A row's contents can be as simple as a single line of text, or comprised of a completely
|
|
459
|
-
customized layout of child views.
|
|
460
|
-
|
|
461
|
-
### Creating Table View Rows
|
|
462
|
-
|
|
463
|
-
Rows may be created using the properties directly available on the `TableViewRow` object, to
|
|
464
|
-
achieve the following:
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
*(See full overview in titanium-docs)*
|
|
468
|
-
|
|
469
|
-
### Properties (unique: 27/95)
|
|
470
|
-
| Property | Type | Default | Platform | Description |
|
|
471
|
-
|----------|------|---------|----------|-------------|
|
|
472
|
-
| accessibilityLabel | String | — | ios | A succinct label associated with the table row for the device's accessibility s… |
|
|
473
|
-
| backgroundSelectedColor | String \| Ti.UI.Color | — | both | Background color to render when the row is selected, as a color name or hex tri… |
|
|
474
|
-
| backgroundSelectedImage | String | — | both | Background image to render when the row is selected. |
|
|
475
|
-
| opacity | Number | — | android | Opacity of this view, from 0.0 (transparent) to 1.0 (opaque). Defaults to 1.0 (… |
|
|
476
|
-
| className | String | — | android | Class name for the row. |
|
|
477
|
-
| color | String \| Ti.UI.Color | — | both | Default text color of the row when not selected, as a color name or hex triplet. |
|
|
478
|
-
| deleteButtonTitle | String | — | both | Text to display on the delete button when editable is enabled |
|
|
479
|
-
| editable | Boolean | undefined | both | Determines the rows' editable behavior, which allows them to be deleted by the … |
|
|
480
|
-
| editActions | Array<RowActionType> | — | ios | Specifies custom action items to be shown when when a list item is edited. |
|
|
481
|
-
| filterAlwaysInclude | Boolean | false | both | This row will always be visible when you filter your content. |
|
|
482
|
-
| font | Font | System default font. | both | Font to use for the row title. |
|
|
483
|
-
| footer | String | — | both | The footer title of the row. |
|
|
484
|
-
| footerTitle | String | — | both | The footer title of the row. |
|
|
485
|
-
| hasCheck | Boolean | false | both | Determines whether a system-provided checkmark is displayed on the right-hand s… |
|
|
486
|
-
| hasChild | Boolean | false | both | Determines whether a system-provided arrow is displayed on the right-hand side … |
|
|
487
|
-
| hasDetail | Boolean | false | both | Determines whether a system-provided detail disclosure button is displayed on t… |
|
|
488
|
-
| header | String | — | both | The header title of the row. |
|
|
489
|
-
| headerTitle | String | — | both | The header title of the row. |
|
|
490
|
-
| indentionLevel | Number | 0 | ios | Indention level for the row. |
|
|
491
|
-
| leftImage | String | — | both | Image to render in the left image area of the row, specified as a local path or… |
|
|
492
|
-
| moveable | Boolean | undefined | both | Determines the rows' moveable behavior, which allows them to be re-ordered by t… |
|
|
493
|
-
| rightImage | String | — | both | Image to render in the right image area of the row, specified as a local path o… |
|
|
494
|
-
| selectedBackgroundColor | String \| Ti.UI.Color | — | both | Background color to render when the row is selected, as a color name or hex tri… |
|
|
495
|
-
| selectedBackgroundImage | String | — | both | Background image to render when the row is selected. |
|
|
496
|
-
| selectedColor | String \| Ti.UI.Color | — | ios | Color of the row text when the row is selected, as a color name or hex triplet. |
|
|
497
|
-
| selectionStyle | Number | — | both | Selection style constant to control the selection color. |
|
|
498
|
-
| title | String | — | both | Text to display on the row. |
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
### Events (4)
|
|
503
|
-
| Event | Platform | Description |
|
|
504
|
-
|-------|----------|-------------|
|
|
505
|
-
| click | both | Fired when a table row is clicked by the user. |
|
|
506
|
-
| touchcancel | ios | Fired when a touch gesture is interrupted by the device. |
|
|
507
|
-
| touchend | ios | Fired when a touch gesture is complete. |
|
|
508
|
-
| touchstart | ios | Fired as soon as the device detects a touch gesture against this view. |
|
|
509
|
-
|
|
510
|
-
### Related Types
|
|
511
|
-
|
|
512
|
-
#### Font
|
|
513
|
-
> An abstract datatype for specifying a text font.
|
|
514
|
-
|
|
515
|
-
| Property | Type | Description |
|
|
516
|
-
|----------|------|-------------|
|
|
517
|
-
| fontFamily | String | Specifies the font family or specific font to use. |
|
|
518
|
-
| fontSize | Number \| String | Font size, in platform-dependent units. |
|
|
519
|
-
| fontWeight | String | Font weight. Valid values are "bold", "semibold", "normal", "thin", "light" and… |
|
|
520
|
-
| fontStyle | String | Font style. Valid values are "italic" or "normal". |
|
|
521
|
-
| textStyle | String | The text style for the font. |
|
|
522
|
-
|
|
523
|
-
---
|
|
524
|
-
|
|
525
|
-
## Ti.UI.TableViewSection
|
|
526
|
-
> A table view section is a container within a table used to organize table view rows.
|
|
527
|
-
> Extends Ti.Proxy
|
|
528
|
-
> Platforms: both
|
|
529
|
-
|
|
530
|
-
Use the <Titanium.UI.createTableViewSection> method or **`<TableViewSection>`** Alloy element to
|
|
531
|
-
create a `TableViewSection`.
|
|
532
|
-
|
|
533
|
-
Before the table is rendered, the `TableViewSection` [add](Titanium.UI.TableViewSection.add)
|
|
534
|
-
method may be used to add [TableViewRow](Titanium.UI.TableViewRow) objects to a section. After
|
|
535
|
-
it is rendered, one of the `TableView` [insertRowBefore](Titanium.UI.TableView.insertRowBefore),
|
|
536
|
-
[insertRowAfter](Titanium.UI.TableView.insertRowAfter), or
|
|
537
|
-
[appendRow](Titanium.UI.TableView.appendRow) methods must be used instead.
|
|
538
|
-
|
|
539
|
-
To remove a row from a section after the table is rendered, use the `TableView`
|
|
540
|
-
[deleteRow](Titanium.UI.TableView.deleteRow) method.
|
|
541
|
-
|
|
542
|
-
In order for a section to be visible, either its `headerTitle` or `headerView` property must be
|
|
543
|
-
configured.
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
*(See full overview in titanium-docs)*
|
|
547
|
-
|
|
548
|
-
### Properties (unique: 6/9)
|
|
549
|
-
| Property | Type | Default | Platform | Description |
|
|
550
|
-
|----------|------|---------|----------|-------------|
|
|
551
|
-
| footerTitle | String | — | both | Title of this section footer. |
|
|
552
|
-
| footerView | Ti.UI.View | — | both | View to use for this section footer. |
|
|
553
|
-
| headerTitle | String | — | both | Title of this section header. |
|
|
554
|
-
| headerView | Ti.UI.View | — | both | View to use for this section header. |
|
|
555
|
-
| rowCount | Number | — | both | Number of rows in this section. |
|
|
556
|
-
| rows | Array<Titanium.UI.TableViewRow> | — | both | Rows in this section. |
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
### Methods (3)
|
|
560
|
-
| Method | Returns | Platform | Description |
|
|
561
|
-
|--------|---------|----------|-------------|
|
|
562
|
-
| add(row) | void | both | Adds a table view row to this section. |
|
|
563
|
-
| remove(row) | void | both | Removes a table view row from this section. |
|
|
564
|
-
| rowAtIndex(index) | Ti.UI.TableViewRow | android | Returns a row in this section. |
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
---
|
|
568
|
-
|
|
569
|
-
## Ti.UI.TableViewScrollPosition
|
|
570
|
-
> A set of constants for the position value that can be used for the `position` property of <Titanium.UI.TableView> when invoking `scrollToIndex`.
|
|
571
|
-
> Extends Ti.Proxy
|
|
572
|
-
> Platforms: both
|
|
573
|
-
|
|
574
|
-
### Constants (4)
|
|
575
|
-
- **OTHER_\***: BOTTOM, MIDDLE, NONE, TOP
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
---
|
|
581
|
-
|