How to simply change the background colour of a cell inside a TableView
Solved
General and Desktop
-
If you call
addMaskedRole
passing eitherQt::DisplayRole
orQt::EditRole
any change will stay in the proxy and not be passed to the source model.You should only mask the roles that you need, in this case
Qt::BackgroundRole
.If it's still not clear, please post us the code using RoleMaskProxyModel and we'll be more specific on the changes to make