You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@pivot.apache.org by MSafiri <zs...@gmail.com> on 2010/11/24 10:43:01 UTC

Sync Tree with Table

Dear All,

Is it possible to sync a TreeView with a TableView? What I mean is the
following:

The screen is cut into two parts, on the left a TreeView is displayed, which
shows the hierarchy between the elements, on the right, a table shows all
the details of all the elements. Each control (TreeView, Table) is in a
ScrollPane. Of course, the two views are not the same. What I would like to
achieve is that when the user selects a node from the TreeView, the table
should highlight the details of the selected node and scroll the table to
show these details.

I hope I was able to explain it well enough.

Thanks alot for your help,

MSafiri
-- 
View this message in context: http://apache-pivot-users.399431.n3.nabble.com/Sync-Tree-with-Table-tp1959691p1959691.html
Sent from the Apache Pivot - Users mailing list archive at Nabble.com.

Re: Sync Tree with Table

Posted by Greg Brown <gk...@mac.com>.
Yes - you can find a preview of the 2.0 docs here:

http://ixnay.biz/pivot-tutorials/

On Nov 24, 2010, at 10:30 AM, MSafiri wrote:

> 
> One tree node - the lowest level within a branch is connected to one row in
> the TableView. This one is one of the simplest task to do :)
> 
> Question: when 2.0 is released, some documentation will be updated as well?
> 
> MSafiri
> -- 
> View this message in context: http://apache-pivot-users.399431.n3.nabble.com/Sync-Tree-with-Table-tp1959691p1961260.html
> Sent from the Apache Pivot - Users mailing list archive at Nabble.com.


Re: Sync Tree with Table

Posted by MSafiri <zs...@gmail.com>.
One tree node - the lowest level within a branch is connected to one row in
the TableView. This one is one of the simplest task to do :)

Question: when 2.0 is released, some documentation will be updated as well?

MSafiri
-- 
View this message in context: http://apache-pivot-users.399431.n3.nabble.com/Sync-Tree-with-Table-tp1959691p1961260.html
Sent from the Apache Pivot - Users mailing list archive at Nabble.com.

Re: Sync Tree with Table

Posted by Greg Brown <gk...@mac.com>.
Yes, it is possible to programmatically scroll a table view.

However, what about the converse? Is there a 1:1 relationship between tree nodes and table rows? If so, what happens when a tree node is expanded? Do you need to add more rows to the table to show the details for the corresponding nodes?

On Nov 24, 2010, at 9:42 AM, MSafiri wrote:

> 
> Greg,
> 
> If the user selects a node in the TreeView, for which the corresponding row
> in the TableView is hidden - he/she should use the scrollbar to access it -
> is it possible to do this scroll via the application? 
> 
> MSafiri
> -- 
> View this message in context: http://apache-pivot-users.399431.n3.nabble.com/Sync-Tree-with-Table-tp1959691p1960952.html
> Sent from the Apache Pivot - Users mailing list archive at Nabble.com.


Re: Sync Tree with Table

Posted by MSafiri <zs...@gmail.com>.
Greg,

If the user selects a node in the TreeView, for which the corresponding row
in the TableView is hidden - he/she should use the scrollbar to access it -
is it possible to do this scroll via the application? 

MSafiri
-- 
View this message in context: http://apache-pivot-users.399431.n3.nabble.com/Sync-Tree-with-Table-tp1959691p1960952.html
Sent from the Apache Pivot - Users mailing list archive at Nabble.com.

Re: Sync Tree with Table

Posted by Greg Brown <gk...@mac.com>.
OK. That is actually easier (though if you want it to look like a TreeTable, where the tree nodes line up perfectly with the table rows, it could be challenging).

On Nov 24, 2010, at 8:46 AM, MSafiri wrote:

> 
> Dear Greg,
> 
> I have seen the TreeTable discussion yesterday. What we planned to do is a
> work around, the two controls are in a different TablePane cell.
> 
> MSafiri
> -- 
> View this message in context: http://apache-pivot-users.399431.n3.nabble.com/Sync-Tree-with-Table-tp1959691p1960698.html
> Sent from the Apache Pivot - Users mailing list archive at Nabble.com.


Re: Sync Tree with Table

Posted by MSafiri <zs...@gmail.com>.
Dear Greg,

I have seen the TreeTable discussion yesterday. What we planned to do is a
work around, the two controls are in a different TablePane cell.

MSafiri
-- 
View this message in context: http://apache-pivot-users.399431.n3.nabble.com/Sync-Tree-with-Table-tp1959691p1960698.html
Sent from the Apache Pivot - Users mailing list archive at Nabble.com.

Re: Sync Tree with Table

Posted by Greg Brown <gk...@mac.com>.
Are you talking about a TreeTable? If so, you may be able to use the approach described in this thread:

http://mail-archives.apache.org/mod_mbox/pivot-user/201011.mbox/%3cB536C556-F6AA-427D-929A-B7918F664980@mac.com%3e

On Nov 24, 2010, at 4:43 AM, MSafiri wrote:

> 
> Dear All,
> 
> Is it possible to sync a TreeView with a TableView? What I mean is the
> following:
> 
> The screen is cut into two parts, on the left a TreeView is displayed, which
> shows the hierarchy between the elements, on the right, a table shows all
> the details of all the elements. Each control (TreeView, Table) is in a
> ScrollPane. Of course, the two views are not the same. What I would like to
> achieve is that when the user selects a node from the TreeView, the table
> should highlight the details of the selected node and scroll the table to
> show these details.
> 
> I hope I was able to explain it well enough.
> 
> Thanks alot for your help,
> 
> MSafiri
> -- 
> View this message in context: http://apache-pivot-users.399431.n3.nabble.com/Sync-Tree-with-Table-tp1959691p1959691.html
> Sent from the Apache Pivot - Users mailing list archive at Nabble.com.