Received: from moniker.gnome.org ([209.116.70.73] helo=mail.gnome.org)
	by plutonium with esmtp (Exim 3.22 #8)
	id 16sEvz-0000Mx-00; Tue, 02 Apr 2002 04:26:11 +0100
Received: from moniker.gnome.org (moniker.gnome.org [127.0.0.1])
	by mail.gnome.org (Postfix) with ESMTP
	id E3D3218302; Mon,  1 Apr 2002 22:26:04 -0500 (EST)
Delivered-To: gtk-list@gnome.org
Received: from renoir.op.net (renoir.op.net [207.29.195.4])
	by mail.gnome.org (Postfix) with ESMTP id 07957180F9
	for <gtk-list@gnome.org>; Mon,  1 Apr 2002 22:25:00 -0500 (EST)
Received: from someip.ppp.op.net (maxtnt02-290.phlpa.fast.net [209.92.228.36]) by renoir.op.net (o1/$Revision: 1.18 $) with ESMTP id WAA17558; Mon, 1 Apr 2002 22:24:55 -0500 (EST)
Message-Id: <200204020324.WAA17558@renoir.op.net>
To: rsteinke@w-link.net
Cc: hunchback@netcabo.pt, gtk-list@gnome.org
Subject: Re: How to set a transparent style? 
In-reply-to: Your message of "Mon, 01 Apr 2002 10:32:46 PST."
             <3CA8A7CE.nailKUI11U84S@w-link.net> 
From: Paul Davis <pbd@Op.Net>
Sender: gtk-list-admin@gnome.org
Errors-To: gtk-list-admin@gnome.org
X-BeenThere: gtk-list@gnome.org
X-Loop: gtk-list@gnome.org
X-Mailman-Version: 2.0.8
Precedence: bulk
List-Help: <mailto:gtk-list-request@gnome.org?subject=help>
List-Post: <mailto:gtk-list@gnome.org>
List-Subscribe: <http://mail.gnome.org/mailman/listinfo/gtk-list>,
	<mailto:gtk-list-request@gnome.org?subject=subscribe>
List-Id: General discussion of GTK+ <gtk-list.gnome.org>
List-Unsubscribe: <http://mail.gnome.org/mailman/listinfo/gtk-list>,
	<mailto:gtk-list-request@gnome.org?subject=unsubscribe>
List-Archive: <http://mail.gnome.org/archives/gtk-list/>
Date: Mon, 01 Apr 2002 17:25:04 -0500
Status:   

>> From: <hunchback@netcabo.pt>
>>
>> Hi, 
>>
>> i'm doing something that involves GtkDrawingArea, in which i paint
>> some GdkPixmaps, and some of this GdkPixmaps have some
>> transparent areas, the problem is when i paint them, the transparent 
>> areas are painted in white! How do i do so that the transparent areas aren't
> 
>> painted?
>
>The problem is, there is no such thing as a GdkPixmap with a transparent
>area. Transparent pixels are handled by setting the clip mask in the
>graphics context. If you created the pixmap from an xpm, the same function
>which created the pixmap also created the mask you need to use.

this is not *quite* true. you can use gdk_window_shape_combine_mask()
to create genuinely transparent areas without setting the clip mask
for every drawing operation. however, using
gdk_window_shape_combine_mask() is not trivial to do in every case.

--p
_______________________________________________
gtk-list mailing list
gtk-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-list