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

HorizontalHeaderView not shown when TableView is empty

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P2: Important
    • None
    • 5.15.1, 6.2.4
    • Quick: Controls 2
    • None
    • Linux/X11, macOS, Windows

    Description

      If I defined columns in a TableModel, but don't defined any row data, the HorizontalHeaderView which binds to a TableView via the syncView property, is not visible. I also tried a C++ model but it behaves the same.

      Only after adding at least one row, the Header delegates get visible.

      If I explicitly set the model to the HeaderView and don't bind via syncView, it gets visible.

      I expected that the HeaderView is always visible, even when the model doesn't contain any rows. Or do I miss something?

      Attachments

        1. Table-Header.tar.gz
          16 kB
        2. Table with one row.png
          Table with one row.png
          30 kB
        3. Table without rows.png
          Table without rows.png
          15 kB
        4. Table with several rows.png
          Table with several rows.png
          72 kB

        Issue Links

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

          Activity

            People

              qt.team.quick.subscriptions Qt Quick and Widgets Team
              voodoo66 Voodoo Master
              Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:

                Gerrit Reviews

                  There are no open Gerrit changes