-
Notifications
You must be signed in to change notification settings - Fork 54
List Item Base Widgets
siddutgikar edited this page Jul 31, 2020
·
2 revisions
Most of the list item widgets follow similar UI traits. To provide ease of implementation and uniform behavior, a set of abstract classes is used to build the list item widgets. These are classified as list item base widgets.
This widget defines the UI elements that each list item should have.
The UI elements can be customized to match the style of the user's application. The customizations can be done using attributes in XML or programmatically using the APIs.
List of the customizable XML attributes
-
uxsdk_list_item_title
- The list item title string. -
uxsdk_list_item_title_appearance
- The list item title appearance. -
uxsdk_list_item_icon
- The list item icon drawable. -
uxsdk_list_item_icon_color
- The list item icon color. -
uxsdk_list_item_title_text_size
- The list item title text size. -
uxsdk_list_item_title_text_color
- The list item title text color. -
uxsdk_list_item_title_text_background
- The background of the list item title. -
uxsdk_list_item_padding_left
- The left padding of the list item content. -
uxsdk_list_item_padding_right
- The right padding of the list item content. -
uxsdk_list_item_padding_top
- The top padding of the list item content. -
uxsdk_list_item_padding_bottom
- The bottom padding of the list item content. -
uxsdk_list_item_disconnected_color
- The color of the list item values when product is disconnected. -
uxsdk_list_item_normal_color
- The color of the list item values when there is no error or warning. -
uxsdk_list_item_warning_color
- The color of the list item values when there is a warning. -
uxsdk_list_item_error_color
- The color of the list item values when there is a error.
List of the customization APIs
-
var listItemTitle: String?
- The list item title string. -
var listItemTitleIcon: Drawable?
- The list item title icon. -
@ColorInt var listItemTitleIconColor: Int
- The list item title icon color. -
var listItemTitleTextSize: Float
- The text size of the list item title. -
@ColorInt var listItemTitleTextColor: Int
- The color of the list item title text. -
var listItemTitleTextColors: ColorStateList?
- The color state list for the item title text. -
var listItemTitleBackground: Drawable?
- The list item title background. -
var contentPaddingLeft: Int
- The left side padding of the list item content. -
var contentPaddingTop: Int
- The top side padding of the list item content. -
var contentPaddingRight: Int
- The right side padding of the list item content. -
var contentPaddingBottom: Int
- The bottom side padding of the list item content. -
fun setListItemTitleBackground(@DrawableRes resourceId: Int)
- Set the list item title background. -
fun setListItemTitleTextAppearance(@StyleRes textAppearanceResId: Int)
- Set the text appearance for list item title. -
fun setContentPadding(left: Int, top: Int, right: Int, bottom: Int)
- Set the padding of the list item content.
This widget has been further expanded into:
DJI UX SDK Version 5 Beta 5
UX SDK 5.0 Overview
Core Module
Camera Core Module
Visual Cameras Module
- Camera Config