Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. SizeHint's "option" seems to be out of date when handed down to function

SizeHint's "option" seems to be out of date when handed down to function

Scheduled Pinned Locked Moved General and Desktop
2 Posts 2 Posters 2.3k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    ronM71
    wrote on last edited by
    #1

    I have a QListView with an AbstractItemDelegate doing the "sizeHint" and "Paint" for my rows.

    My goal:

    Every "mouse-over" row should double in height so that I can draw more on it.

    problem:

    In my paint method: the "option.state & QStyle::State_MouseOver" is always correct and i use it to slightly highlight the row the mouse cursor is on...

    in my SizeHint method however, the "option.state & QStyle::State_MouseOver" is always "off", even if the row is currently under my mouse. This makes it impossible for me to suggest a different height for the row base don that case.

    Is that a Qt bug?

    1 Reply Last reply
    0
    • A Offline
      A Offline
      andre
      wrote on last edited by
      #2

      There certainly are issues in that area of Qt. I've ran into similar problems before.

      Edit:
      See for instance this "report":http://bugreports.qt.nokia.com/browse/QTBUG-11227.

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved