Hello!
We use standard WPF and are evaluating your framework. My collegue Petr Osipov has already been in contact with you as he is evaluating your charts framework.My first task is to see if you support a "Tree-Table", or some similar solution.
Question 1:We currently use a basic tree (WPF TreeView), and, for each line in the tree, would like to show the Line-Number. This we would like to show in a separate column, totally left-adjusted, and not indented, and always in-sync with the lines of the tree control. Essentially it is a separate list, hopefully with each row-element being clickable. Please see the attached graphic "Tree-Table-Description.png" and it should become clear what I mean.
In the graphic I have simply added the line numbers with Paint .NET for demonstration effects. Please notice: where elements are collapsed, the Line-Numbers are still added up correctly. Therefore, in the picture, we have Line 1, then Line 39, as the "ASPHeader" element is collapsed.
The Line-Number is simply a property in a view-model element.
The Line-Numbers must of course always be up-to-date, reflecting the current contents of the tree:- When we change the contents of the tree, the Line-Numbers must also be updated, via data-binding- If I were to expand the "ASPHeader" element, the Line-Number list must be accordingly updated, showing the previously-hidden contents of "ASPHeader".
How would I best achieve this with your framework? Would I use- XamDataTree, or- XamDataGrid, or- XamGrid- XamPivotGrid?
Question 2:We also work with selection and highlighting of elements. Selection seems pretty clear. But, how would I go about highlighting elements and sub-elements? For instance, in our tree, if a particular element is selected, and that element has children, all children in the tree are highlighted (background color set), recursively down for all possible children. How can I achieve this effect? Using the WPF TreeView I did this:
<Style.Triggers> <DataTrigger Binding="{Binding IsHighlighted}" Value="True"> <Setter Property="Background" Value="{StaticResource HighlightedItemBackground}" /> </DataTrigger> </Style.Triggers>
Question 3:Admittedly I have not yet looked too hard but: I created a small demo-program, with a VM and a view based on the XamDataTree component. I pump it full with say 1,000,000 VM elements. It is quite fast! Scrolling and selection work on this scale, whereas the Microsoft component just craps out, and is extremely slow. Great work! However, out-of-the-box, standard windows bindings like page-up, page-down, expand-all (keyboard+'*') do nothing. In the basic tutorial for the XamDataTree I see nothing about turning on these standard bindings. How does this work?
I would take this opportunity to thank you for your help in advance. We are nearing a decision on buying a WPF replacement-framework and Infragistics is currently number one, at least for charts. We also want to replace standard WPF trees and grids, and therefore my fairly detailed questions here.
I may post more questions specifically pertaining to XamDataGrid and XamGrid.
Kindest Regards,
Mark HorowitzRohde & Schwarz, Germany
Hello Mark,
Thank you for your post. I have been looking into it and I created a sample project for you where I implemented the functionality you want. Basically I copied the default Style of the XamDataTreeNodeControl and add a TextBlock inside it, which I bound to the ViewModel LineNumber Property in order to show the line numbers. As for the selection, I set the XamDataTree’s CheckBoxMode to Auto and when I select a Node, I set its IsChecked Property to true, this way all his children are Checked too. I used the IsChecked Property to highlight the Node via Trigger in the XamDataTreeNodeControl Style. Regarding your 3-rd question I can say that XamDataTree doesn’t have built in Bindings for the functionalities you mention. So I can suggest you implement them in a way that suits you best.
Hope this helps you.
Ok thanks Stefan, in particular for the enclosed solution.Pertaining to question 2: I referred to "highlighting" and not "selecting", i.e. we set the background color and don't change the selection.But, you gave me some insights into the problem, anyway.
Pertaining to question 3: Does that mean that none of the ig components, for instance XamDataGrid, XamGrid, and XamPivotGrid, have the windows-standard bindings automatically enabled?
I'm going to evaluate further - my next goal is to actually substitute your ig:XamDataTree for microsoft:TreeView.
Cheeers,Mark
The XamGrid control has a built-in functionality for page-up, page-down and expand/collapse active row(+/-). The XamDataGrid has only page-up and page-down, but you can use its ExecuteCommand method and execute some of the DataPresenterCommands, where there is ExpandAll command. The XamDataTree has only support for expand/collapse the selected node.
Thanks Stefan!Mark