Details
-
User Story
-
Resolution: Unresolved
-
Not Evaluated
-
None
-
None
-
89
-
Foundation Sprint 118, Foundation Sprint 119, Foundation Sprint 120, Foundation Sprint 121, Foundation Sprint 122, Foundation Sprint 123, Foundation Sprint 124, Foundation Sprint 125, Foundation Sprint 126, Foundation Sprint 127
Description
Goal
Introduce a QML type to create and store tree-like data structures (e.g. JavaScript/JSON objects) for a tree model to be used with TreeView. It is intended to support simple models with pure QML; without requiring the creation of a custom QAbstractItemModel subclass in C++.
Description
The model can be stored as a simple collection of nodes with hierarchical relationship between them. A node can have multiple children but only one parent (with the exception of the root node)
The basic functionalities are expected from QML:
Node management:
- Dynamically add or remove nodes
- Enable node set/update (directly in the model or by using custom delegates)
- Be able to move a node in the structure
Tree traversal
- Easily traverse the tree model
- Iterate the model
Relationship:
- Parent and child access on the node level
Event handling:
- Be able to update the tree on changes in the model
Data validation:
- Consider invalid models, for instance, a child having multiple parents
Tree data:
- Be able to query the number of edges and the depth of a node
Notes
- Consider performance implication for large data sets.
- Consider future improvements where user could add data from XML tree models or JSON files.
- Consider future improvements to search the model
- Consider the possibility to switch the same model as tree or table view.
Attachments
1.
|
Add a method to validate input |
|
In Progress | Máté Barany |
2.
|
Implement some rules for subtree movements |
|
Reported | Máté Barany |
3.
|
Clean up internal structure |
|
In Progress | Máté Barany |
4.
|
Add tests |
|
Reported | Máté Barany |
5.
|
Add documentation |
|
Reported | Máté Barany |
6.
|
Revisit API |
|
Reported | Máté Barany |
7.
|
Revisit internal structure |
|
Reported | Máté Barany |