mirror of
https://github.com/KDE/konsole.git
synced 2026-05-07 14:16:40 -04:00
just install the two new schemes (Transparent.scheme and GreenTint.scheme) and select them. It works for gradient, tiled and centred backgrounds TODO:Just have to fix the rest of the "tiled" modes (except tiled itself) You can define new tints with the transparency setting in the schema file, just have a look at the examples. Konsole now generates the background and keeps a cache while it's in the same desktop. I've had to change it to be a KWMModuleApplication and connect a few signals for resizes and desktop changes. I've tried to design it so that it's easy to change if we ever make kbgndwm put the backgrounds in shared memory. svn path=/trunk/kdebase/konsole/; revision=21717
35 lines
842 B
C++
35 lines
842 B
C++
#ifndef SCHEMA_include
|
|
#define SCHEMA_include
|
|
|
|
#include <qstring.h>
|
|
#include "TECommon.h"
|
|
#include <qdict.h>
|
|
#include <qintdict.h>
|
|
|
|
struct ColorSchema
|
|
{
|
|
public:
|
|
QString path;
|
|
int numb;
|
|
QString title;
|
|
QString imagepath;
|
|
int alignment;
|
|
ColorEntry table[TABLE_COLORS];
|
|
bool usetransparency;
|
|
double tr_r, tr_g, tr_b; // The ratio with which the pixels color component
|
|
// is multiplied, i.e. if tr_r = tr_g = tr_b = 0.5, a
|
|
// pixel as (255,0,32) (a red pixel) will be converted to
|
|
// (127,0,16)
|
|
public:
|
|
static ColorSchema* readSchema(const char* path);
|
|
static ColorSchema* find(const char* path);
|
|
static ColorSchema* find(int num);
|
|
static ColorSchema* defaultSchema();
|
|
static void loadAllSchemas();
|
|
static int count();
|
|
public:
|
|
void addSchema();
|
|
};
|
|
|
|
#endif
|