* BUG: Sunken and raised borders are now drawn correctly with styles like 
  CleanLooks that incorrectly take the current painter brush into account.


git-svn-id: svn://localhost/gambas/trunk@5615 867c0c6c-44f3-4631-809d-bfa615b0a4ec
This commit is contained in:
Benoît Minisini 2013-04-07 14:39:24 +00:00
parent 80e53c8dbd
commit 03f1b78370

View file

@ -504,6 +504,7 @@ void CCONTAINER_draw_frame(QPainter *p, int frame, QStyleOptionFrame &opt, QWidg
QStyle *style;
QStyleOptionFrameV3 optv3;
bool a;
QBrush save_brush;
//QRect rect = opt.rect;
if (frame == 0)
@ -533,7 +534,11 @@ void CCONTAINER_draw_frame(QPainter *p, int frame, QStyleOptionFrame &opt, QWidg
optv3.rect = opt.rect;
optv3.state = opt.state | QStyle::State_Sunken;
optv3.frameShape = QFrame::StyledPanel;
save_brush = p->brush();
p->setBrush(QBrush());
style->drawPrimitive(QStyle::PE_Frame, &optv3, p, w);
p->setBrush(save_brush);
//style->drawControl(QStyle::CE_ShapedFrame, &optv3, p, w);
break;