Content:
- Examples
- Properties
- Methods

A TreeView is a hierarchical representation of data, often used to display nested categories or organized information.*

var items = {
"Group 1": {
"Item 1": "",
"Item 2": "",
"Item 3": ""

},
"Group 2": {
"Item 1": "",
"Item 2": "",
"Item 3": ""

},
"Applications": {
"Editor": "",
"Productivity": "",
"Social Media": {
"TikTok": "",
"YouTube": "",
"Meta": {
"Facebook": "",
"Instagram": "",
"Whatsapp": "",
"Messenger": ""
}
}

}

}

`var items = {"Group 1": {"Item 1": "","Item 2": "","Item 3": ""},"Group 2": {"Item 1": "","Item 2": "","Item 3": ""},"Applications": {"Editor": "","Productivity": "","Social Media": {"TikTok": "","YouTube": "","Meta": {"Facebook": "","Instagram": "","Whatsapp": "","Messenger": ""}}}}`


The properties of the list object will be the name of the item or the group.

trv = ui.addTreeView( parent, list?, options?, width?, height? ) → ui object: TreeView

If you add a string value to the list object properties, it will be treated as an icon.
See example below

#Example - Items with iconsvar items = {"Folders": {"Music": "music_note","Photos": "photo","Favorites": "favorite"}}

Here are the available methods of the TreeView Component.

Examples

Example - Basic TreeView click to expand contents 

Properties

The following properties are available on the TreeView object:

absHeightNumber
absLeftNumber
absTopNumber
absWidthNumber
backColorString
backImageString
borderNumber
borderColorString
borderStyleString
cornerRadiusNumber
disabledBoolean
elObject
elStyleString
fontFileString
heightNumber
isVisibleBoolean
leftNumber
listObject
marginsList
opacityNumber
optionsString
paddingList
parentObject
positionObject
rotationNumber
textColorString
textSizeNumber
topNumber
typeString
valueString
visibilityString
widthNumber

Methods

The following methods are available on the TreeView object:

getItem( name ) → Object
getPosition( options ) → Object
gone()
hide()
setScale( x, y )
show()