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

Bring header view APIs in line with other Controls

    XMLWordPrintable

Details

    • Task
    • Resolution: Unresolved
    • P2: Important
    • 6.0.0
    • None
    • Quick: Controls 2
    • None

    Description

      We need to figure out which API from e.g. Control we will have in HorizontalHeaderView and VerticalHeaderView.

      Property Included Reason
      QFont font Allows changing font of every delegate without overriding it
      qreal availableWidth Not necessary if we don't have padding
      qreal availableHeight Not necessary if we don't have padding
      qreal padding Not sure how useful padding properties are when you're trying
      to align stuff to the sync'd TableView
      qreal topPadding  
      qreal leftPadding  
      qreal rightPadding  
      qreal bottomPadding  
      qreal spacing Already present (columnSpacing/rowSpacing) in TableView
      QLocale locale Like font, this is a fundamental property
      bool mirrored ?  
      Qt::FocusPolicy focusPolicy ? Not sure if we really need the focus-related properties or not...
      Qt::FocusReason focusReason ?  
      bool visualFocus ?  
      bool hovered Probably not useful if delegates will be handling clicks
      (e.g. responding to a click by calling a sort function)
      bool hoverEnabled  
      bool wheelEnabled Should be added to Flickable if necessary, not here
      QQuickItem *background Provides some convenience and familiarity, but
      it is quite easy to achieve already:
      Rectangle { anchors.fill: parent; color: "red"; z: -1 }
      Also, see the note for implicitBackgroundWidth: traditional implicit size calculations
      for controls don't really make sense for header views, so this has even less value, I think
      QQuickItem *contentItem Already present in Flickable
      qreal baselineOffset Not applicable
      QPalette palette Already handled by https://codereview.qt-project.org/c/qt/qtdeclarative/+/270092 in Qt 6
      qreal horizontalPadding See padding
      qreal verticalPadding See padding
      qreal implicitContentWidth Shorthand for contentItem ? contentItem.implicitWidth : 0,
      but since header views always have a contentItem, this doesn't give us much...
      though if we do add background, it might be odd to have
      implicitBackgroundWidth/Height and not this
      qreal implicitContentHeight  
      qreal implicitBackgroundWidth Should be added if we add background, although
      the background should probably always just fill the view, since the view's size should be
      aligned with the size of the sync'd TableView; it doesn't make sense to do the traditional
      implicit size calculations
      qreal implicitBackgroundHeight  
      qreal topInset See padding
      qreal leftInset  
      qreal rightInset  
      qreal bottomInset  

      Attachments

        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
            mitch_curtis Mitch Curtis
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes