weixin_44740398: paint里面可以这么写 就可以用样式表设置背景色了 QStyleOptionViewItem opt = option; if(index.row() == m_hoverRow) { opt.state |= QStyle::State_MouseOver; } else { opt.state &= ~QStyle::State_MouseOver; } return QStyledItemDelegate::paint(painter, opt, index);
linux系统,不定时kernel bug :soft lockup的问题
[转]QTableView实现鼠标悬浮(hover)行高亮显示