blob: 83c19acef496d35e339bf84fcc38009fda0c0b66 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
/***************************************************************************
kjbackground.cpp
--------------------------------------
Just draws the main-pixmap of a KJ�fol-Skin
--------------------------------------
Maintainer: Stefan Gehn <[email protected]>
***************************************************************************/
#include "kjbackground.h"
KJBackground::KJBackground(KJLoader *parent)
: KJWidget(parent)
{
QImage ibackground;
mBackground = parent->pixmap(parser()["backgroundimage"][1]);
ibackground = parent->image(parser()["backgroundimage"][1]);
parent->setMask( getMask(ibackground) );
parent->setFixedSize ( QSize(mBackground.width(), mBackground.height()) );
setRect(0,0,parent->width(),parent->height());
}
void KJBackground::paint(QPainter *painter, const QRect &rect)
{
bitBlt(painter->device(), rect.topLeft(), &mBackground, rect, Qt::CopyROP);
}
|