Use
Qt Code:
  1. QVariant(Qt::black)
To copy to clipboard, switch view to plain text mode 

EDIT: But your code will even with this not compile since you are trying to set a QString on a QColor...