qt中实现区域反白效果 QPainter p(this); p.setCompositionMode(QPainter::CompositionMode_Difference); p.fillRect(e->rect(), Qt::white);