自定义控件常用的 缩放
int width = label->width();
int height = label->height();
QPixmap map("/dir/xxx.png");
map = map.scaled (width, height, Qt::IgnoreAspectRatio, Qt::SmoothTransFormation);
label->setPixmap(map);
取消控件的焦点响应事件, 可以这么操作
label->setAttribute( Qt::WA_TransparentForMouseEvents, true );