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

ListView.section documentation does not state multiple sections can get created

    XMLWordPrintable

Details

    • f14ac31c86eeb53d0b08c799ad0ad895d17475d6

    Description

      Maybe this is obvious but wasn't for me:
      ListModel {
      id: animalsModel
      ListElement

      { name: "Elephant"; size: "Large" }

      ListElement

      { name: "Parrot"; size: "Small" }

      ListElement

      { name: "Guinea pig"; size: "Small" }

      ListElement

      { name: "Dog"; size: "Medium" }

      ListElement

      { name: "Cat"; size: "Medium" }

      }

      With the above model (and example in the docs), two sections called Large are created. The ordering of the items in the model is maintained. I was expecting this to be some sort of sophisticated proxy model which groups things of the same criteria together.

      So, please either fix code or the docs.

      Attachments

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

        Activity

          People

            martjone Martin Jones (closed Nokia identity) (Inactive)
            girish Girish Ramakrishnan
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes