Quantcast
Channel: Qt DevNet forums: Qt Quick 1283365070**
Viewing all articles
Browse latest Browse all 4972

How do you simulate a tree view in Qt Quick since it's not included in Controls 1.0?

$
0
0
As mentioned in another recent post, I’m new to Qt Quick, so please bear with me. Project background: A coworker sketched up a GUI design for a new cross-platform application intended to replace a legacy, Windows (MFC) application. He intends to have a couple of nested split views, a tree view, and a couple of swappable editor panes. Issue at hand: Qt Quick Controls 1.0 doesn’t include a stock TreeView (though I believe I read it’s planned for 5.2). I need to simulate said TreeView to fulfill the design requirements for this GUI. Implementation ideas: Perhaps I could utilize a ListView whose ListModel contains ListElement entries that may hold their own nested ListElement entries (and so on). This model could approximate a tree structure that a user might need to navigate in a GUI. Concerns: I have a severe lack of experience with Qt Quick and feel I am not familiar enough with the available components and now they relate to/interact with each other in order to implement this control quickly. Would someone be able to suggest a path forward on implementing such a control? I’m open to other ideas on how to handle the navigation, but I would also like to know how to implement something (seemingly) as simple as this control should be. Thanks! PS: I’m afraid I don’t have any example code to post since I just don’t think I’m doing anything correctly right now, but I hope my description is clear.

Viewing all articles
Browse latest Browse all 4972

Trending Articles