You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
#ifndef _BACKGROUND_H
|
|
|
|
#define _BACKGROUND_H
|
|
|
|
#include <tqstring.h>
|
|
|
|
|
|
|
|
class TQPixmap;
|
|
|
|
class TQImage;
|
|
|
|
|
|
|
|
|
|
|
|
class Background
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
public:
|
|
|
|
Background();
|
|
|
|
~Background();
|
|
|
|
bool tile;
|
|
|
|
|
|
|
|
bool load(const TQString &file, short width, short height);
|
|
|
|
void sizeChanged(int newW, int newH);
|
|
|
|
void scaleModeChanged();
|
|
|
|
TQPixmap *getBackground() {return backgroundPixmap;}
|
|
|
|
TQPixmap *getShadowBackground() {return backgroundShadowPixmap;}
|
|
|
|
private:
|
|
|
|
void sourceToBackground();
|
|
|
|
|
|
|
|
int tileMode; // scale background = 0, tile = 1
|
|
|
|
TQImage *backgroundImage;
|
|
|
|
TQImage *sourceImage;
|
|
|
|
TQPixmap *backgroundPixmap;
|
|
|
|
TQPixmap *backgroundShadowPixmap;
|
|
|
|
TQString filename;
|
|
|
|
short w;
|
|
|
|
short h;
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|