Qt Code:
  1. painter.setBrush(QBrush(QColor(0, 0, 0, 255)));
To copy to clipboard, switch view to plain text mode 
That makes it black instead of white.

Qt Code:
  1. CustomRubberBand *selection = new CustomRubberBand(QRubberBand::Rectangle, 0);
  2. selection->setGeometry(150,150,250,250);
  3. selection->show();
To copy to clipboard, switch view to plain text mode 
There is no effect with "selection->setWindowOpacity(0.0);" at all.