QPainter类的一些问题

时间:2023-01-05 11:17:40
   QPainter painter1(this);//新建类
   painter1.setRenderHint(QPainter::Antialiasing,true);//设置反锯齿
   painter1.setBrush(QBrush(/*Qt::green,*/ QPixmap(":/qmlicon/qmlicon/timeclock.png").scaled(size())));//添加填充颜色和图片
   painter1.setPen(Qt::NoPen);//设置外框颜色为NoPen
   painter1.drawEllipse( 1,  1, side - 2, side - 2);//开始画圆