> - is it possible (for example using a style property) to display a
> tree also without the root node ?
>

The tree data reference itself is never displayed -- its children are the
"root nodes".  So if you want a tree that looks like it has a single root
node, your tree data would have one child.  If you want a tree that looks
like it has several root nodes (or looks like the root is not being shows),
then your tree data would contain N children.


> - for the row coloring, is it possible to attach to some event and
> change the background color of the desired row (using application
> custom strategies like zebra, by level, etc ... useful for example
> with tree tables), or the Tree has to be subclassed ?
>

It'd be the responsibility of the skin and isn't currently supported.  The
tree table use case would be a good reason to support alternating row colors
in a tree view (I had forgotten that use case in yesterday's discussion).
You can create a JIRA ticket for that if you like - I'd mark it against 1.5,
unless you plan to tackle it sooner.


> - is implemented a standard method (maybe visible also from style) to
> expand all, collapse all, and expand selection (only) ?
>

expandAll and collapseAll are not implemented because it's not hard to do in
application code.  A simple tree traversal with calls to setExpanded() would
do the trick.  With only operating on the selection, it's even easier,
because you just iterate over the selected paths (getSelectedPaths()).


> - to implement a Tree Table, do you think simple cases could be
> handled adding to any node a TableRow element (containing with many
> fields), or is it better to write a new component (ok in the general
> case) ? derived from Tree ?
>

Practically speaking, you'd want to write your own component for tree table
-- one which would *use* both a tree view and a table view internally.  You
could probably make it work without encapsulating the behavior in a
component, but it wouldn't be as clean and would lead to ambiguity as to
which component's events should be listened to.  But yes, you would end up
adding table rows to the tree data, which is also supported right now (tree
data is List<?>).

Reply via email to