Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    QTableView: delegate::paint() is not called when mouse leaves the widget

    General and Desktop
    1
    1
    1013
    Loading More Posts
    • 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.
    • L
      lijo last edited by

      Hi,

      I use a QTableView along with my custom delegate and model. I have enabled mouse tracking for QTableView. When the mouse enters a table cell, I draw an icon in the cell and clears this icon when the mouse leaves the cell, using delegate's paint method. When mouse moves from one cell to another, paint methods are called for both previous and current cells as expected.

      However, when the mouse moves out of the tabeview widget from a cell, delegate's paint method is not getting called for that cell. As a result I am not able to clear the icon for that cell. I could see reference to this issue in another thread as well [1]. Is this behavior a bug?

      I am using Qt4.8.3 ATM. I would try with Qt5 as well, possibly with a test program. It would be great if any one knows about this issue already. Thanks in advance.

      [1] http://qt-project.org/forums/viewthread/13099/#99344

      1 Reply Last reply Reply Quote 0
      • First post
        Last post