summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDanny Baumann <dannybaumann@web.de>2008-07-17 18:15:44 +0200
committerDanny Baumann <dannybaumann@web.de>2008-07-17 18:15:44 +0200
commitaaa191f5c77dff5a03de5b4d2c614e7e55631fa4 (patch)
tree48473c3011b6670ba6dac74b77c190e8c42c9508
parent1fd27f4f11df26c8d9c23b92207b7b9beafb26fd (diff)
parent4abb3ddb7b43ec254fd751c44b1317c310f0dd60 (diff)
downloadgroup-aaa191f5c77dff5a03de5b4d2c614e7e55631fa4.tar.gz
group-aaa191f5c77dff5a03de5b4d2c614e7e55631fa4.tar.bz2
Merge branch 'master' of git+ssh://maniac@git.opencompositing.org/git/fusion/plugins/group
-rw-r--r--cairo.c9
-rw-r--r--group-internal.h7
2 files changed, 14 insertions, 2 deletions
diff --git a/cairo.c b/cairo.c
index 308b6ab..d06dbfb 100644
--- a/cairo.c
+++ b/cairo.c
@@ -79,6 +79,9 @@ groupDestroyCairoLayer (CompScreen *s,
finiTexture (s, &layer->texture);
+ if (layer->pixmap)
+ XFreePixmap (s->display->display, layer->pixmap);
+
if (layer->buffer)
free (layer->buffer);
@@ -104,6 +107,7 @@ groupCreateCairoLayer (CompScreen *s,
layer->surface = NULL;
layer->cairo = NULL;
layer->buffer = NULL;
+ layer->pixmap = None;
layer->animationTime = 0;
layer->state = PaintOff;
@@ -711,7 +715,10 @@ groupRenderWindowTitle (GroupSelection *group)
layer->texHeight = height;
if (data)
- bindPixmapToTexture (s, &layer->texture, (Pixmap) data,
+ {
+ layer->pixmap = (Pixmap) data;
+ bindPixmapToTexture (s, &layer->texture, layer->pixmap,
layer->texWidth, layer->texHeight, 32);
+ }
}
diff --git a/group-internal.h b/group-internal.h
index 4ef1d80..f3d4244 100644
--- a/group-internal.h
+++ b/group-internal.h
@@ -228,11 +228,16 @@ typedef enum {
} TabbingState;
typedef struct _GroupCairoLayer {
- unsigned char *buffer;
CompTexture texture;
+
+ /* used if layer is used for cairo drawing */
+ unsigned char *buffer;
cairo_surface_t *surface;
cairo_t *cairo;
+ /* used if layer is used for text drawing */
+ Pixmap pixmap;
+
int texWidth;
int texHeight;