Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-93014

TreeView: create separate TreeViewDelegate

    XMLWordPrintable

Details

    • Task
    • Resolution: Unresolved
    • Not Evaluated
    • None
    • None
    • None

    Description

      Create a TreeViewDelegate that can be more easily styled from the platform / app. The idea is that you can then do:

      TreeView {
          delegate: TreeViewDelegate {
              TreeView.isExpanded: true
              indicator: Text{ text: TreeView.isExpanded ? "-" : "+" }
              icon: TreeView.isTreeColumn ? model.icon : null
              text: model.display
              alternateRows: false
          }
      } 

      But should it use one delegate for the tree, and another for the other columns? Or use TreeView.isTreeColumn?

      Should TreeViewDelegate set icon and text from the model by default?

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              richard Richard Moe Gustavsen
              richard Richard Moe Gustavsen
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:

                Gerrit Reviews

                  There are no open Gerrit changes