h = uitree()
h = uitree(parent)
h = uitree(..., propertyName, propertyValue)
| Paramètre | Description |
|---|---|
| parent | parent object. |
| propertyName, propertyValue | name-value pairs. |
| Paramètre | Description |
|---|---|
| h | UI object. |
t = uitree crée un arbre ; uitree(parent, 'checkbox') crée un arbre à cases à cocher. Les enfants sont des objets uitreenode. Propriétés : SelectedNodes, Multiselect (arbre standard), CheckedNodes/CheckedNodesChangedFcn (arbre à cases), Editable, SelectionChangedFcn, NodeExpandedFcn, NodeCollapsedFcn. Utiliser expand(t) / collapse(t).
f = uifigure('Visible', 'off', 'Name', 'Tree', 'Position', [100 100 420 260]);
tr = uitree(f, 'Position', [70 40 210 180]);
n1 = uitreenode(tr, 'Text', 'Fruits');
uitreenode(n1, 'Text', 'Apple');
uitreenode(n1, 'Text', 'Banana');
expand(tr);
drawnow();
f = uifigure();
t = uitree(f);
n1 = uitreenode(t, 'Text', 'Fruits');
n2 = uitreenode(n1, 'Text', 'Pomme');
expand(t);
| Version | Description |
|---|---|
| 2.0.0 | initial version |